Community Support Forums — WordPress® ( Users Helping Users ) — 2011-12-25T04:28:11-05:00 http://www.primothemes.com/forums/feed.php?f=4&t=16382 2011-12-25T04:28:11-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=58759#p58759 <![CDATA[Re: Question about free days]]>

Statistics: Posted by Cristián Lávaque — December 25th, 2011, 4:28 am


]]>
2011-12-22T20:54:16-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=58593#p58593 <![CDATA[Re: Question about free days]]>

Quite elegant the way you used the S2MEMBER_CURRENT_USER_REGISTRATION_DAYS to check if they're not logged in!

Statistics: Posted by Raam Dev — December 22nd, 2011, 8:54 pm


]]>
2011-12-22T19:06:59-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=58576#p58576 <![CDATA[Re: Question about free days]]>
Here's my own version of that condition that seems to do the job, but is simpler to write:

Code:
<?php if (current_user_can('access_s2member_level1') || S2MEMBER_CURRENT_USER_REGISTRATION_DAYS < 4) { ?>

Video content would go here.

<?php } else { ?>

PayPal button code to purchase access would go here..

<?php } ?>


I basically checks if the user can access Level 1 content, or if his account has less than 4 days of having been created (i.e. 3 days). This condition would be true for any account in its first 3 days, even free users, or for any paid members at Level 1 or above. It'd be false for anyone else: someone not logged in, or a free user whose account is older than 3 days.

Sorry about that video, I was sure it had an explanation of the shortcode conditionals, but I watched it again and that version of s2Member seems to not have had it yet. The documentation for them in the Scripting API page is simple enough if you read it and go through the examples. I was only suggesting these to show the button in the Login Welcome page for the approach I suggested first. Shortcodes don't support the conditions that check how old the account is, for that I was suggesting the EOT instead.

The PHP condition needs to be used in each post, like Raam said. You can also create a hack to apply this condition to every post in a certain category. For an example of a conditional used in a similar way, please watch the second video on Custom Capabilities, starting around time 7:00.

embed

Checking the user registration days with a condition, doesn't require s2Member Pro, but it needs the hack or adding the condition in every post.

What I suggested first would work well, but it does require s2Member Pro's free registration pro-form to create free accounts at Level 1 with an EOT. viewtopic.php?f=4&t=16382&p=58576#p56735

Statistics: Posted by Cristián Lávaque — December 22nd, 2011, 7:06 pm


]]>
2011-12-22T15:43:27-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=58538#p58538 <![CDATA[Re: Question about free days]]>

You will need to put that code on each video post and it will then automatically work when you browse the categories.

Statistics: Posted by Raam Dev — December 22nd, 2011, 3:43 pm


]]>
2011-12-22T09:39:48-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=58498#p58498 <![CDATA[Re: Question about free days]]>
and thank you, realy helps me a lot!!

Statistics: Posted by MatijaS — December 22nd, 2011, 9:39 am


]]>
2011-12-20T20:35:04-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=58329#p58329 <![CDATA[Re: Question about free days]]>
There is no shortcode logic for what you are trying to do (it may be added in a future version of s2Member). However, you can still accomplish this business logic using Advanced PHP Conditionals and PHP Constants provided by s2Member.

You will need to install the PHP Execution plugin and then use PHP code in your posts to control the content dripping based on how long the user has been registered.

Here's an example that you could use on a post where you want to show/sell a video:

Code:
<?php if (S2MEMBER_CURRENT_USER_ACCESS_LEVEL === 0 && S2MEMBER_CURRENT_USER_REGISTRATION_DAYS < 3 || s2member_paid_registration_time() > 0) { ?>

    [ video content would go here ]

<?php } else if (S2MEMBER_CURRENT_USER_ACCESS_LEVEL === 0 && S2MEMBER_CURRENT_USER_REGISTRATION_DAYS > 3) { ?>

    [ PayPal button code to purchase access would go here. ]

<?php } ?>



In the example above, free registered users (S2MEMBER_CURRENT_USER_ACCESS_LEVEL === 0) who have been registered for 3 days or less (S2MEMBER_CURRENT_USER_REGISTRATION_DAYS < 3) OR registered users who have paid you (s2member_paid_registration_time() > 0) will be shown the video content.

If they're a free registered user who has been registered for more than three days (S2MEMBER_CURRENT_USER_ACCESS_LEVEL === 0 && S2MEMBER_CURRENT_USER_REGISTRATION_DAYS > 3), the PayPal button to purchase access will be shown instead of the video content.

Statistics: Posted by Raam Dev — December 20th, 2011, 8:35 pm


]]>
2011-12-20T14:46:50-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=58293#p58293 <![CDATA[Re: Question about free days]]> In video don"t show this.
I don"t find shortcode, which would solve my example!

Thanks

Statistics: Posted by MatijaS — December 20th, 2011, 2:46 pm


]]>
2011-12-19T18:04:10-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=56963#p56963 <![CDATA[Re: Question about free days]]> WP Admin -> s2Member -> API / Scripting -> Simple/Shortcode Conditionals

This video also talks about them and you may find it helpful: http://www.s2member.com/api-scripting-overview-video/

I hope that helps.

Statistics: Posted by Cristián Lávaque — December 19th, 2011, 6:04 pm


]]>
2011-12-18T19:00:24-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=56852#p56852 <![CDATA[Re: Question about free days]]> can you please show me an example for API Scripting (short code).

Thank you very much!

Statistics: Posted by MatijaS — December 18th, 2011, 7:00 pm


]]>
2011-12-17T04:02:24-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=56735#p56735 <![CDATA[Re: Question about free days]]>
You could do this with s2Member Pro's free registration pro-form. This would allow you to have users register and get the 3 days of access at the level you wish to give, and he'd be demoted to Level 0 after the 3 days you specified for the EOT (end of term).
WP Admin -> s2Member -> PayPal Pro-Forms -> Free Registration
WP Admin -> s2Member -> PayPal Options -> Automatic EOT Behavior


At that point, he'd be shown a button to pay for premium access. This button could be in the Login Welcome Page and shown only to those at Level 0 using a conditional.
WP Admin -> s2Member -> General Options -> Login Welcome Page
WP Admin -> s2Member -> API / Scripting -> Simple/Shortcode Conditionals


I hope this helps. :)

Statistics: Posted by Cristián Lávaque — December 17th, 2011, 4:02 am


]]>
2011-12-15T16:52:27-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=56610#p56610 <![CDATA[Re: Question about free days]]>
I dont think that this what are you write to me is possible for my case.

So look, if someone visits our site and register it. I want that that person to watch free of charge one category( otherwise
is payable), but after three days, access to these categories close and the paypal button appered.

I am sory,but it is my first time with thoose kind a thing.

Thanks.

Statistics: Posted by MatijaS — December 15th, 2011, 4:52 pm


]]>
2011-12-15T08:49:42-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=56587#p56587 <![CDATA[Re: Question about free days]]> If yes then it's very simple, you can use content dripping, which you can find under WP Admin -> s2Member -> API / Scripting -> s2Member Content Dripping.

Hope this helps. :)

Statistics: Posted by Eduan — December 15th, 2011, 8:49 am


]]>
2011-12-15T08:18:48-05:00 http://www.primothemes.com/forums/viewtopic.php?t=16382&p=56585#p56585 <![CDATA[Question about free days]]>
I have one question. I am using s2member plugin, and I wonder, if I can do one thing??!!

-- i would like to every member that will register on website, have 3 days unlimited access and after 3 days paypal button will show up..

I did a thing, that i put out the paypal buton,and choose that they will have 3 days for free, but is that this that I want?? i dont want,that they after 3 days must pay.... i would like,that they have to choose wheter or not they want to pay!!

thanks!!!!

www.forex-trading-signals.info

Statistics: Posted by MatijaS — December 15th, 2011, 8:18 am


]]>