Page 1 of 1

Advice on Error Handling ...

Posted: Wed Dec 26, 2007 10:35 am
by jmueller0823
We utilize several Includes which output
results from a MySQL script.

The Includes look like this:

Code: Select all

<? include "http://www.site.com/php/psDynamic/psDynamic.php?command=view&cid=89" ; ?>
This code is trouble-free until we encounter the occasional SQL error.
If an error occurs, (obviously) a MySQL error displays and screws up the screen.

What I'd like to do is add some error handling.

Something like...
  • Try the Include
  • If result contains text 'failed' or '503', then do not display, then exit.
  • Display Include
Is this possible?
Thanks!

Posted: Wed Dec 26, 2007 10:39 am
by John Cartwright

Posted: Thu Dec 27, 2007 1:49 pm
by feyd
Security recommendation: do not ever EVER EVER include a remote file.