[FX.php List] How to stop error with bad username/password

Andrew Denman adenman at tmea.org
Tue Nov 20 10:05:14 MST 2007


It sounds like you might be getting an FX.php error instead of a FileMaker
error.  Chris' advice will work here:

"When FX encounters a serious error, it returns an FX Error Object, instead
of the standard data array.  This means that you should check for errors
each time you query FileMaker something like this:"

if (FX::isError($searchResult)) {
     ... code here to handle FX.php errors ...
} elseif ($searchQuery->lastErrorCode != 0) {
     ... code here to handle FileMaker errors ...
} else {
     ... your normal data returning code here ...
}

Andrew Denman

-----Original Message-----
From: fx.php_list-bounces at mail.iviking.org
[mailto:fx.php_list-bounces at mail.iviking.org] On Behalf Of Glenn Singleton
Sent: Monday, November 19, 2007 8:35 PM
To: 'FX.php Discussion List'
Subject: [FX.php List] How to stop error with bad username/password

Hi 

I am getting an error from PHP when trying to connect to a fp7 file with an
invalid username/password combination.

Invalid layout and database not available errors are handled by fx.php, but
username/password seems to trigger an error before fx.php.

How do I trap this error gracefully.

Sample code would really help rather than just a reference to a function.

Thanks
Glenn Singleton

_______________________________________________
FX.php_List mailing list
FX.php_List at mail.iviking.org
http://www.iviking.org/mailman/listinfo/fx.php_list



More information about the FX.php_List mailing list