latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Member Since

Home Forums Community Forum Member Since

This topic contains 5 replies, has 3 voices. Last updated by  Eduan 3 years, 11 months ago.

Topic Author Topic
Posted: Saturday Jan 26th, 2013 at 9:14 am #39684

i’d like to create a line such as “You’ve been a member since DATE”

From what I could find in the shortcodes, I found
[s2Get constant="S2MEMBER_CURRENT_USER_REGISTRATION_DAYS" /]
which returns the number of days.

So I worded it as
You’ve been a member for [s2Get constant="S2MEMBER_CURRENT_USER_REGISTRATION_DAYS" /] days.

But I’d prefer to convert that to the actual date, not x number of days.

If there a shortcode for registration DATE (not “paid registration – initial reg date regardless)
or do I have to use some php code to do date calculations?

thanks guys, great job

List Of Topic Replies

Viewing 5 replies - 1 through 5 (of 5 total)
Author Replies
Author Replies
Posted: Saturday Jan 26th, 2013 at 9:26 am #39686
Hamid
Username: zawiyaprojects

You could use the following:

<?php echo "Member Since: " . date('M j, Y', S2MEMBER_CURRENT_USER_REGISTRATION_TIME); ?>
Posted: Tuesday Jan 29th, 2013 at 1:20 pm #39909
Eduan
Username: Eduan
Moderator

Try what Hamid offered, it should work. :)

Posted: Tuesday Jan 29th, 2013 at 2:15 pm #39918

works perfectly, thanks

Posted: Tuesday Jan 29th, 2013 at 2:21 pm #39920

while we’re discussing this, I use your easy php plugin to insert php code in post. Every time I re-edit the page, it doesn’t work. Is that common, or just my editor messing things up? (it either gets commented out, or parts of the code are lost probably going back and forth from text to visual editor)

<?php turns into <–?
thanks

  • This reply was modified 3 years, 11 months ago by  Vincent Miele.
  • This reply was modified 3 years, 11 months ago by  Vincent Miele.
Posted: Thursday Jan 31st, 2013 at 2:44 pm #40177
Eduan
Username: Eduan
Moderator

Hello Vincent,

If you are using PHP code (or any kind of code) in your posts, once you insert it you should NOT go back to visual mode, if you do the code will be broken by WordPress, without question.

– Eduan

Viewing 5 replies - 1 through 5 (of 5 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.