Using Current User Registration Days in a formula
-
I seem to be having issues using Current User RegistrationDays in a formula. I’ve been able to use other S2Get User fields in formulas on my pages. Posting [s2Get constant=”S2MEMBER_CURRENT_USER_REGISTRATION_DAYS” /] displays the proper number of days. However, I’d like to get the total weeks that the user has been registered and be able to use this as a variable.
Here’s an example of my code that doesn’t seem to be working. I’ve tried playing with the structure of the [s2Get constant=”S2MEMBER_CURRENT_USER_REGISTRATION_DAYS” /] request to no avail.
<script>
var User_days = [s2Get constant=”S2MEMBER_CURRENT_USER_REGISTRATION_DAYS” /];
var User_weeks = (User_days/7);
document.write(User_weeks);
</script>
- The topic ‘Using Current User Registration Days in a formula’ is closed to new replies.