PDA

View Full Version : User has not posted for x days


neverstop
12-08-2009, 12:50 PM
HI,

I see that the notcies system allows you to show a notice to someone who hasnt posted in X days.

I am looking for somethig similar as a template conditional. So something like:

<in condition="user has not posted in x days">fu</if>


Is something like this is possible?

--------------- Added 1260284142 at 1260284142 ---------------

OK I see that there is a 'lastpost' field in the user table...

so this is obviously possible using TIMENOW but I need help with the conditional syntax please.

--------------- Added 1260285070 at 1260285070 ---------------

<if condition="$bbuserinfo['lastpost'] > (TIMENOW - 86400)">



When I try that I get an error saving the templates saying the > is a function that can be used in a confditional....


I think i have the "> <" signs mixed up but when i try "<" it doesnt seem to work

Lynne
12-08-2009, 01:22 PM
This article should help you. Take a look at it and see if you can figure it out now - Perform simple calculations inside templates! (https://vborg.vbsupport.ru/showthread.php?t=188930) (If you can't post what you last tried and I'll see what I can do.)