helmut2509 Posted October 5, 2017 Share Posted October 5, 2017 Hello, In my pw app I am using a webservice to fetch data for a selectbox. Sporadically (not always!) I cannot json_decode the json string I get from the webservice, I get json error code 4 (syntax error). When this occurs I also get the following error message: "Severity: Core Warning Message: PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/php_soap.dll' - /usr/lib/php/20151012/php_soap.dll: cannot open shared object file: No such file or directory". ....though I do NOT use a soap function! the strange thing is that I fetch always the same data and sometimes it works, sometimes it does not work. Any suggestions? Link to comment Share on other sites More sharing options...
JoshoB Posted October 5, 2017 Share Posted October 5, 2017 6 minutes ago, helmut2509 said: Sporadically (not always!) Could it be a connection error? You said you're using a webservice (third party?), so that would be my guess. Link to comment Share on other sites More sharing options...
helmut2509 Posted October 5, 2017 Author Share Posted October 5, 2017 Just now, JoshoB said: Could it be a connection error? You said you're using a webservice (third party?), so that would be my guess. It's not a third party webservice, it' my own ;-) Link to comment Share on other sites More sharing options...
abdus Posted October 5, 2017 Share Posted October 5, 2017 Find your php.ini and comment out this line ;extension=php_soap.dll To find php.ini you can use echo php_ini_loaded_file(); http://php.net/manual/en/function.php-ini-loaded-file.php Link to comment Share on other sites More sharing options...
helmut2509 Posted October 5, 2017 Author Share Posted October 5, 2017 1 minute ago, abdus said: Find your php.ini and comment out this line ;extension=php_soap.dll that's already done..... But I wonder from where this extension is called??? My php code is in no way related to soap! Link to comment Share on other sites More sharing options...
abdus Posted October 5, 2017 Share Posted October 5, 2017 4 minutes ago, helmut2509 said: that's already done..... I know, but 30 minutes ago, helmut2509 said: Unable to load dynamic library this error points out that some ini file somewhere is trying to load the php_soap extension from an nonexistent path. To find if there's a call to soap methods, you can perform a project wide search using the methods here http://php.net/manual/en/book.soap.php Link to comment Share on other sites More sharing options...
helmut2509 Posted October 5, 2017 Author Share Posted October 5, 2017 5 minutes ago, abdus said: I know, but this error points out that some ini file somewhere is trying to load the php_soap extension from an nonexistent path. To find if there's a call to soap methods, you can perform a project wide search using the methods here http://php.net/manual/en/book.soap.php I guess the error is somehow related to the $session-object (of PW). When I logout and then login again, all works fine (in the majority of cases). But then at subsequent calls of one page the error occurs again. Link to comment Share on other sites More sharing options...
JoshoB Posted October 5, 2017 Share Posted October 5, 2017 12 minutes ago, helmut2509 said: I guess the error is somehow related to the $session-object (of PW). How so? PW doesn't use SOAP, as far as I know. What does the error log say, specifically? Where does the error occur? What code is being executed when the error pops up? Link to comment Share on other sites More sharing options...
helmut2509 Posted October 5, 2017 Author Share Posted October 5, 2017 6 minutes ago, JoshoB said: How so? PW doesn't use SOAP, as far as I know. What does the error log say, specifically? Where does the error occur? What code is being executed when the error pops up? This is my code: if(!isset($session->sprachen)){ $action = 'fetchdata/sprachen'; $resultJson = sendData($webserviceUrl,$action,$params); echo "sprachen vom webservice:".$resultJson.'<p>';//correct json string. after the string comes //the error message "Unable to load dynamic library '/usr/lib/php/20151012/php_openssl.dll'" $session->sprachen = json_decode($resultJson,true); echo "json-error-code-sprachen=".json_last_error().'<p>';//here json error 4 occurs (syntax error?!) echo "sprachen22:<pre>";print_r($session->sprachen);echo " count-sprachen=".count($session->sprachen)."</pre>";//$session->sprachen is empty! } Link to comment Share on other sites More sharing options...
helmut2509 Posted October 6, 2017 Author Share Posted October 6, 2017 On 5.10.2017 at 5:24 PM, helmut2509 said: This is my code: if(!isset($session->sprachen)){ $action = 'fetchdata/sprachen'; $resultJson = sendData($webserviceUrl,$action,$params); echo "sprachen vom webservice:".$resultJson.'<p>';//correct json string. after the string comes //the error message "Unable to load dynamic library '/usr/lib/php/20151012/php_openssl.dll'" $session->sprachen = json_decode($resultJson,true); echo "json-error-code-sprachen=".json_last_error().'<p>';//here json error 4 occurs (syntax error?!) echo "sprachen22:<pre>";print_r($session->sprachen);echo " count-sprachen=".count($session->sprachen)."</pre>";//$session->sprachen is empty! } I found it: there was still another dll-entry in the php.ini I had to comment out. Now it works like a charm. But I still do not understand, why and where these components have been referenced and why this error occurred simoultaneously with a json syntax error...and only sporadically. very strange! Link to comment Share on other sites More sharing options...
BitPoet Posted October 6, 2017 Share Posted October 6, 2017 59 minutes ago, helmut2509 said: But I still do not understand, why and where these components have been referenced and why this error occurred simoultaneously with a json syntax error...and only sporadically. very strange! It's likely just the current PHP instance in FastCGI or the Apache child reaching its maximum lifetime. Depending on the web server and how PHP is invoked, a new PHP instance is spun up every so often. The new PHP instance gets loaded, and if error reporting is active, it just coughs this warning into the next output stream. So it has nothing to do with calling soap methods. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now