Kristian_C Posted August 20, 2007 Share Posted August 20, 2007 Hey people, everybody happy? :)just wanted to know if there was a way to not display mysql connection error's?like :Insted of :Warning: mysql_connect(): Access denied for user '^^^'@'^^^^^^' (using password: YES) in /home/content/u/n/i/^^^^/^^^^/^^^^/^^^^/^^^^ on line ^^^^Warning: mysql_select_db(): Can't connect to local MySQL server through socket '/usr/local/mysql-5.0/data/mysql.sock' (2) in /home/content/u/n/i/^^^^/^^^^/^^^^/^^^^/^^^^ on line ^^^^Warning: mysql_select_db(): A link to the server could not be established in /home/content/u/n/i/^^^^/^^^^/^^^^/^^^^/^^^^ on line ^^^^to be displayd, this will insted :Hello, a system error has showd up, pleace wait a few hours for us to fix the problem.is it possible?-------------Kristian_C Link to comment Share on other sites More sharing options...
Matpatnik Posted August 20, 2007 Share Posted August 20, 2007 You can add "@" like this @$con = mysql_connect("localhost","username","password");if (!$con) { die('Could not connect: ' . mysql_error());}@mysql_select_db("database_name", $con); Link to comment Share on other sites More sharing options...
Kristian_C Posted August 20, 2007 Author Share Posted August 20, 2007 So thats the reason iv'e seen those @'s in connection scripts .. Thanks -Kristian_C Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.