Page 1 of 1

What is the @ before son Varible for

Posted: Tue Feb 13, 2007 7:59 am
by baselbj
i am new at PHP and I've seen some code that look like this :

if (@$_POST['action']!="login")

what i need to know is what is the use of "@" before the $_POST variable. and what will happen if i dropped it ?

i don't know if this question is a stupid but can you help me :roll:

Posted: Tue Feb 13, 2007 8:02 am
by onion2k
It tells PHP to suppress any error messages. It's bad and wrong and you should never use it.

Posted: Tue Feb 13, 2007 8:33 am
by ryuuka
@ is the devil mkay

Posted: Tue Feb 13, 2007 9:07 am
by baselbj
thank you for your help