[FX.php List] resource for testing for errors

Tim 'Webko' Booth tim at nicheit.com.au
Tue Jul 29 21:58:52 MDT 2008


On 30/07/2008, at 1:51 PM, Kathy Mohr wrote:

> I am trying to find a good resource for creating php error testing
> scripts.  I've tried using the below code but both message are  
> displayed
> when the error code value is 0.  What am i doing wrong or where can  
> I find
> how to do this correctly?

Try quoting your 0 result... and you shouldn't use short php start  
tags these days. I also tend to run that test the other way around

So:

<?php if($createResult['errorCode'] != "0"){ ?>
          An Error Occurred. Please make sure you have entered your  
correct ID. If you continue to get an error message, please contact etc
<?php }else{ ?>
     You have successfully registered for the below event.
<?php } ?>

See how that goes...


More information about the FX.php_List mailing list