How to catch error?
Posted: Tue Dec 02, 2003 11:47 pm
Hi:
I use pg_connect() to connect to my postgresql database, when there is a mistake, the php engine will echo the error message, can someone tell me how to catch this error message to give its value to a variable. I guess error_handler can do, any other methods?
eg. I want to catch this error message and make it the value of a variable named $messagebody, and then send it to my mailbox.
sincerely
Yuping Wang
I use pg_connect() to connect to my postgresql database, when there is a mistake, the php engine will echo the error message, can someone tell me how to catch this error message to give its value to a variable. I guess error_handler can do, any other methods?
eg. I want to catch this error message and make it the value of a variable named $messagebody, and then send it to my mailbox.
sincerely
Yuping Wang