10.07.2015 Views

SuiteTalk (Web Services) Platform Guide - NetSuite

SuiteTalk (Web Services) Platform Guide - NetSuite

SuiteTalk (Web Services) Platform Guide - NetSuite

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Getting StartedUsing <strong>Web</strong> <strong>Services</strong> with PHP27• $myNSclient = new nsClient( nsHost::live );• $myNSclient = new nsClient( nsHost::beta );• $myNSclient = new nsClient( nsHost::sandbox );• $myNSclient = new nsClient( “http://localhost:5050” );5. Enable SOAP by editing the php.ini file in C:\Windows. Add the line"extension=php_soap.dll" under Dynamic Extensions.6. To log SOAP, add a folder called nslog under the same folder where you have placedPHPtoolkit.php. The toolkit will automatically send SOAP to this folder. If you want tostop logging SOAP, rename the folder.Troubleshooting PHP and <strong>Web</strong> <strong>Services</strong>The following table provides solutions for problems that may be encountered when using PHPwith <strong>NetSuite</strong> <strong>Web</strong> services.ProblemThe following error is returned whenattempting to send requests over https:Fatal error: Uncaught SoapFault exception:[WSDL] SOAP-ERROR: Parsing WSDL:Couldn't load from 'https://webservices.netsuite.com/wsdl/v2011_2_0/netsuite.wsdl'The following time out error is returned:Fatal error: Maximum execution time of 30seconds exceededThe following error message is returned:Debug Error: Uncaught SoapFaultexception: [HTTP] Error Fetching httpheadersThe following error message is returned:Warning: It is not yet possible to assigncomplex types to propertiesThe execution of script stops and error wasnot shown, or notices are being shown onthe pageThe following error is returned:Fatal error: Allowed memory size of8388608 bytes exhausted (tried to allocate3024 bytes)SolutionEdit the php.ini file by uncommenting"extension=php_openssl.dll" under Dynamic ExtensionsMake sure that libeay32.dll and ssleay32.dll files are in yourpath. In Windows you can do this by copying the files to yourSystem32 folder.Edit the php.ini file and change max_execution_time - 30 (ordefault value) to 200Edit the php.ini file and by setting default_socket_timeout =200Open the php.ini file and edit error_reporting. Set it toE_ERROR instead of E_ALLOpen the php.ini file and set error_reporting = E_ERROR &~E_NOTICEOpen the php.ini file and set memory_limit = 80M<strong>SuiteTalk</strong> <strong>Platform</strong> <strong>Guide</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!