Discussions
Stay up-to-date with the latest news from NetSuite. You’ll be in the know about how to connect with peers and take your business to new heights at our virtual, in-person, on demand events, and much more.
New AI Community Guidelines. Please review and follow them to ensure AI use stays safe, accurate, and compliant.
Update: Narrative Insights has been restored and is now available.
Narrative Insights is Temporarily Unavailable due to an Infrastructure Issue. Learn how This Impacts Your Account and What to Expect While the Feature is Disabled.
Narrative Insights is Temporarily Unavailable due to an Infrastructure Issue. Learn how This Impacts Your Account and What to Expect While the Feature is Disabled.
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) {
0