Discussions
Read on for the latest updates including:
• Agenda Builder launch
• SuiteWorld On Air registration
• New NetSuite Prompt Studio Contest
• And more!
Check out this thread to learn more!
how to get soap fault exception codes
I'm trying to catch exceptions thrown when a soap api uses an invalid login credential using PHP toolkit.
The following code doesn not print either the message or the code :
catch(Exception $e) {
print $e->getMessage() . '<br />' . $e->getCode();
die;
}
however if I dump the $e exception, I get this whole object :
object(SoapFault)#10 (10) {
["message":protected]=>
string(56) "You have entered an invalid password. Please try again."
["string":"Exception":private]=>
string(0) ""
["code":protected]=>
int(0)
["file":protected]=>
string(66) "***/PHP_Toolkit/rokutest/PHPtoolkit.php"
["line":protected]=>
int(1638)
["trace":"Exception":private]=>
array(3) {