Integrating Google Spreadsheet no longer works after it has worked for months. Although I haven't changed anything. I get the error message. Error: Table in data source has no rows.
RedirectsFor security reasons, content returned by the Content service isn't served from script.google.com, but instead redirected to a one-time URL at script.googleusercontent.com. This means that if you use the Content service to return data to another application, you must ensure that the HTTP client is configured to follow redirects.
What you can try is to add this code in file wp-content/plugins/wpdatatables/source/class.wdttools.php around line 205 you will find this
curl_setopt($ch, CURLOPT_REFERER, site_url());
and below that add this code
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
so your code will look like this
We need to test more but for now it is working in all test cases.
Integrating Google Spreadsheet no longer works after it has worked for months. Although I haven't changed anything. I get the error message. Error:
Table in data source has no rows.
The link to the Google spreadsheet is:
https://docs.google.com/spreadsheets/d/1wuzKXF3ob1BVPd5SSaorrOXmAsnQ1KH4wx_RpPWbzOw/edit#gid=0
The link to the page on which I present the table is
https://gleisdreieck-blog.de/2020/04/23/corona-alltag-im-park/
Thanks in advance for your help
Hi buelow,
Thank you for reporting this.
After investigation, we found out that your link in converted in this after CURL call
Temporary RedirectTemporary Redirect The document has moved here https://doc-10-60-sheets.googleusercontent.com/pub/.....
The described behavior is a feature:
https://developers.google.com/apps-script/guides/content#redirects
What you can try is to add this code in file wp-content/plugins/wpdatatables/source/class.wdttools.php around line 205 you will find this
and below that add this code
so your code will look like this
We need to test more but for now it is working in all test cases.
Sorry for inconvenience,
Kind Regards,
Isidora Markovic
wpDataTables: FAQ | Facebook | Twitter | Front-end and back-end demo | Docs
Amelia: FAQ | Facebook | Twitter | Amelia demo sites | Docs
You can try our wpDataTables add-ons before purchase on these sandbox sites:
Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables
FYI, my google sheets stopped loading today and this fixed it