PHP -- still time problem the following code is to implement daily login, then 2 points will be added & nbsp; error: Parseerror: syntaxerror, unexpectedT_VARIABLEinC: \ AppServ \ www \ user_reg \ login. phponline28 & nb PHP-time issues
The following code is used to add 2 points for daily login.
Error: Parse error: syntax error, unexpected T_VARIABLE in C: \ AppServ \ www \ user_reg \ login. php on line 28
$ Thistime = date ("Y-m-d"); // 28 rows
$ Lasttime = $ row ['logtime'];
If ($ thistime-$ lasttime) >=86400)
{Mysql_query ("update register set logTime = now () where id = $ result ['id']");
Mysql_query ("update register set score = $ row ['score '] + 2 where id = $ result ['id']");
}
Also, do you not know if the if statement is correct? Beginner ~~~~ Enlighten me
------ Solution --------------------
Echo 'you have earned logon points today: '. $ row ['score'];
Again, the string connector is. not a comma
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service