Shortcodes for the Mobile Display layout

  • Carlo
    Newbie 14 points
    April 24, 2015 at 3:27 pm


    I’ve been using on my website Richard Bonk’s (btw – thanks for the great job 😉 )Limit Content Plugin to have the Contact Author button on my Listing Pages to appear only for certain Memberships:


    I’ve notice that the new Mobile Display layout doesn’t support this feature, so the Contact Author button appears to everybody on mobile phones (nullifying the fact of stopping people to write to each other without my authorization 🙂 ).
    Is there a way to have this working also on mobile devices too? I’m quite happy to get my hands dirty and modify the Themes files, but I couldn’t find the file that was coding the listing pages for the mobile view.

    Thanks to all,
    Carlo 🙂

  • Mark
    Titan 733 points
    April 24, 2015 at 7:34 pm

    Look into the files that have the word ‘mobile’ in them such as:


    The one that is most likely to control the listings would be content-single-listing-mobile.php


  • Carlo
    Newbie 14 points
    April 24, 2015 at 8:07 pm

    Hi Mark,

    thanks for your reply… yes I did notice the files with the _mobile naming and had a look at them. Unfortunately I couldn’t find anything that indicated what I was looking for.
    Will give another look but if there is some other idea I’m here to listen 🙂

    Have a nice day

  • Josh
    Super Guru 13,875 points
    April 25, 2015 at 10:31 am

    Hello Carlo
    Have you tried the [MEMBERSHIP] shortcode eg [MEMBERSHIP ID=”1,2,3″][CONTACT button=1] [/MEMBERSHIP]

  • Carlo
    Newbie 14 points
    April 25, 2015 at 2:01 pm

    Hi Josh!
    The shortcode I used works just fine.
    The problem is that the Mobile View doesn’t support shortcodes in general… so on the normal website everything is as I want it but on mobiles I get a “standard mobile page” that is not customizable.
    For now I’ve solved the issue by deleting the file content-single-listing-mobile.php, making a copy of the file content-single-listing.php and renaming it as content-single-listing-mobile.php.
    What that does is to force on the Mobile interface the responsive listing page with all of his shortcodes.
    Thought this as a temporary solution, while trying to understand how the file was set-up… but have to say that it looks quite nice, so I might keep it as final 😉

  • Josh
    Super Guru 13,875 points
    April 25, 2015 at 2:37 pm

    Thanks for sharing 🙂

  • Robin
    Newbie 5 points
    August 11, 2016 at 8:29 pm

    Has anyone found a more proper solution for this? Still an issue, unable to add shortcodes in the mobile view… the switch to responsive view is less than ideal.


  • Marie
    Super Guru 1,818 points
    August 12, 2016 at 2:01 am

    Hi Robin,

    The mobile version is still on beta version. There’s no option to have shortcode on mobile view yet.

Viewing 8 posts - 1 through 8 (of 8 total)

New Business Themes for WordPress 2020

Start your new website today!

View Business Themes