PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
I am still new to php and I have already seen this @ quite a few times, but I can't seem to find it in the manual.
Also, I have tried the mysql_* functions without the @ prefixing them and they all seem to work fine. Can anyone tell me what exactly is the purpose of the @ before these function call
@functionname() will suppress any error messages the function returns. So if you connect to the database with @mysql_connect, and the connection fails, it won't show any warning messages. But if you just use mysql_connect and it fails, it'll spit out lots of warning messages.
that's kinda what I thought. However, I dunno about the last part of that comment. When I try and connect to MySQL and it fails, I don't get any error messages at all. Only way I know to get it to error, is to put a "or die("blah blah blah ERROR R4R"); clause in it heh..