When coding the connection part of a php page, I have it so if the connection fails, it gives my special message saying: too many connections, try again later.
This is what I use, and it will show the message when it cannot connect, but then it stops showing the rest of the page after that:
if (!@mysql_connect ($server, $db_user, $db_pass))
exit("Unable to connect, please try later.");
How can I have it so if the connection fails, it gives my message, stops the php/mysql connection/commands, but yet shows the rest of the page? exit and die both halt displaying the rest of the page. Add something to the function? Use another function?
Thanks in advance.
- The Maxx