• Resolved jitka88

    (@jitka88)


    Hi,

    I used your plugin often, it’s really helpfull to build some user restricted content based on woocommerce, thanks for that!

    One question – is there any way ho to recognize the page is restricted?

    Example: I have a site, where is multicurrency switcher. I’d like to hide it (by CSS) on the locked pages (there is restricted content so user shouldn’t be distracted by anything but the content).

    On this page: https://www.janaliscova.cz/ the restricted content are pages, posts… and I’d like to distinguish, which are normal pages a and which are the locked ones.

    Do you have any advice? If not, could you add it as a feature? I believe it’d be helpfull to have this information e.g. in the body class list (there is the post type, some builder information… etc).

    Thank you!

    J.

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter jitka88

    (@jitka88)

    PS: I found the class “wc_ppp_paywall”, but it’s only on locked page. I nedd the oposite – to know, that the page is normally locked, but if you bought the access, you can see it.

    Any other way than migrate to custom post type? 🙂

    Thanks

    Plugin Author Matt Pramschufer

    (@mattpramschufer)

    Hurm… interesting idea. So you are looking to add a body class to any page that is protected regardless of if they have access or not, and then another body class if they have access? Something like

    <body class='ppp-protected ppp-has-access'>
    
    
    Thread Starter jitka88

    (@jitka88)

    Ideally, yes. Both of them – when visitor has access and when it’s not.

    <body class='ppp-protected ppp-has-access'>

    and

    <body class='ppp-protected ppp-has-not-access'>

    The usecase is – there is currency changer on the page and I need to hide it, when use is on restricted content (he already has access, and it’s not product page, so no need for currency changer 🙂

    Thanks!

    Plugin Author Matt Pramschufer

    (@mattpramschufer)

    @jitka88 I love the suggestion and I will work on getting that included in an upcoming release. I can’t give you an eta on when but I can tell you it will be included as soon as I can.

    Thread Starter jitka88

    (@jitka88)

    It’s amazing to hear that, thank you! I’ll wait for it.

    J.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Body CSS class for restricted content’ is closed to new replies.