My users can upgrade their accounts to "silver" and "gold" accounts.
I use this function to set account validation time for 30 days:
$time = time();
$exptime = $time + 30 3600 24;
sql_query("update portal_users set validation= '$exptime' where username='$user'", $dbi);
that's ok so far, but some users want to renew accounts before they expire. so I have to update time keeping existing validation time: existing time + new time
Validation time in mysql looks like this: "1109737055"
So, I can not just update table in this way:
sql_query("update portal_users set validation= validation+'$exptime' where username='$user'", $dbi);
Any ideas?
Thanks!