-
Notifications
You must be signed in to change notification settings - Fork 154
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
String could not be parsed as XML #46
Comments
Hi, Can you paste the code you're using and explain how you're generating the access token. Thanks |
I have the same issue. Up until today I was using the library from Nov 3 and now downloaded current version. What worked before no longer works // obtain an access token from Google $serviceRequest = new DefaultServiceRequest( $accessToken ); $spreadsheetService = new SpreadsheetService(); The exception: ( ! ) Fatal error: Uncaught exception 'Exception' with message 'String could not be parsed as XML' in www\php-google-spreadsheet-client\src\Google\Spreadsheet\SpreadsheetFeed.php on line 45 Time Memory Function Location1 0.0040 414208 {main}( ) ..\rosterexport.php:0 |
Dear All, With the help of asimlqt I was able to create an update script for my Google Spreadsheet. Unfortunately during the update/insert process I get many times the same error as well what you described above (and in the Subject) -> Fatal error: Uncaught exception 'Exception' with message 'String could not be parsed as XML' in /google-api-php-client/src/Google/Spreadsheet/CellFeed.php:137 Stack trace: #0 /google-api-php-client/src/Google/Spreadsheet/CellFeed.php(137): SimpleXMLElement->__construct('') #1 /wwwroot/html_parser_test.php(337): Google\Spreadsheet\CellFeed->updateBatch(Object(Google\Spreadsheet\Batch\BatchRequest)) #2 {main} thrown in /google-api-php-client/src/Google/Spreadsheet/CellFeed.php on line 137..... I checked many forums and possible solutions BUT till now none of them helped to solve this issue. I use the following code to create the AccessToken: $client = new Google_Client(); $cred = new Google_Auth_AssertionCredentials( $client->setAssertionCredentials($cred); if($client->isAccessTokenExpired()) { $obj_token = json_decode($client->getAccessToken()); $serviceRequest = new DefaultServiceRequest($accessToken); //Working with the SpreadSheet Any ideas how can I solve this issue? I appreciate all helps because I have to solve this problem asap. Thanks for your help in advance! BR, |
I have the same issue with : $spreadsheetFeed = $spreadsheetService->getSpreadsheets(); public function __construct($xml)
It always displays "Empty XML". I think the request is not working properly. Any suggestions ? Regards, |
Same here: [code] => 500 |
I'm going to add improved error handling in the next version. |
hi all
l'm a new comer for php. l want to get data from google spread sheet , l use the php-google-spreadsheet-client, now l got some trouble.
Fatal error: Uncaught exception 'Exception' with message 'String could not be parsed as XML' in....
someone can help?
The text was updated successfully, but these errors were encountered: