Support » Plugin: s2Member Framework (Member Roles, Capabilities, Membership, PayPal Members) » If/then shortcode or php for users on free trial?

  • Is there a shortcode or php conditional to target users who are currently on their free trial?

    The reason I would like this is to hide download links from users who are on their free trial. This way, they can have access but not download and run.

    I checked the API scripting but didn’t find anything related to this.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Yes, the shortcode works like this:

    [s2If current_user_is(s2member_level0)]
        Some content for Free Subscribers.

    Thanks for the reply. However, I do not believe this will work for a free trials

    Per Jason’s instructions, I am using the proform shortcode: [s2Member-Pro-PayPal-Form register=”1″ level=”2″ ccaps=”” success=”/first-time-login/” custom=”” tp=”3″ tt=”D” captcha=”0″ /] to create a free trial user for 3 days.

    As such, when the user is created, they are given a role (in this case level 2). So, I cannot use that shortcode to target them because they are level 2, not level 0.

    It would likely have to be a shortcode that targets the eot data?

    Sorry, didn’t read that properly! I don’t think there is a shortcode for that.

    Instead, though, if you are giving everyone on that level a free trial, you could use the One-Time Offers capability to redirect trialists users to a specific page. (Although it says “One Time,” there’s nothing to stop you doing it for the second and third days too.)


    Is there a way to php a conditional that hooks into the users end of trial date or identify the user is on a trial? It seems S2member has that data since when I look at users there is an EOT column, suggesting s2member is storing that data/identification somewhere.

    Sadly, one-time offers won’t work since I am giving them free trial access to an entire course. They need to access all the pages and have a user level.

    Well, I’m sure there is a way to do it with some code. But you’ll need a coder for that (and that’s certainly not me)!

    krumch is probably the person to ask. Look at some of the other topics for details of how to get hold of him.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘If/then shortcode or php for users on free trial?’ is closed to new replies.