2012-08-01 114 views
1

,我发现了以下错误:的Display.php的PHP解析错误:语法错误,意想不到的T_IS_EQUAL,期待

PHP Parse error: syntax error, unexpected T_IS_EQUAL, expecting ',' 
or ')' in C:\etc\display.php on line 115 

行115:

if ((!isset($_POST['login']==NULL) OR !isset($_POST['passwd']==NULL))) msgerror("<font size=4>Fill all the missing fields and try again.</font>");

我敢肯定,这关于使用ISSET的语法问题,但我无法摆脱这个错误,并使其工作(对于成为这样一个新手抱歉)。

回答

0

只需卸下==NULL S,他们是完全不必要的,我不知道我能明白为什么你把它们放在那里摆在首位...

而且,最好使用||代替的or

0

试试这个:

if (!isset($_POST['login']) || empty($_POST['login']) || !isset($_POST['passwd']) || empty($_POST['passwd'])) 
msgerror("<font size=4>Fill all the missing fields and try again.</font>"); 
+0

''标记已被弃用;你应该使用CSS进行造型 – Don 2012-08-01 19:43:52

相关问题