1. peterva
  2. RO CSVI
  3. Sunday, 17 July 2016
  4.  Subscribe via email
Hi, I am trying to automatically import a csv file from Google Spreadsheets.

The url Google gives me looks like this:
https://docs.google.com/spreadsheets/d/1zxun9_LvrPXjSER3Zh-OyvYAUso2qlazYMLdcxmFY1k/pub?gid=0&single=true&output=csv

When I test this url in the CSVI template config, I get the message 'The URL has been tested and is valid.'

However, when I run the import, I get an error that the .csv extension is missing:

Error
No extension has been found on the uploaded file /var/www/saint/tmp/com_csvi/1468776321/pub_output_csv, now I don't know what to do with your file. Please check your file if it has a valid extension. Valid extensions are csv, tsv, txt, xml, xls and ods.

Is there a workaround for this?
Accepted Answer Pending Moderation
I have found a workaround already. Here it is:

download the Google Spreadsheet file to my server:
wget --no-check-certificate --output-document=myfilename.tsv 'https://docs.google.com/spreadsheets/d/GOOGLE-ID/pub?gid=0&single=true&output=tsv'

Set 'myfilename.tsv' as the source file in the template.

Now the import works fine and can be automated with a cronjob.
  1. more than a month ago
  2. RO CSVI
  3. # 1
Accepted Answer Pending Moderation
Thank you for posting your solution.
Kind regards,

Tharuna

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 2
Accepted Answer Pending Moderation
Hello Peter,

There should not be a need to download the spreadsheet with wget. What you can do is in your template enforce the type of import file. On the File tab of your template click on Advanced to show the advanced settings and then set the option Use file extension to CSV. Finally save the template, this should be it :)
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 3
  • Page :
  • 1


There are no replies made for this post yet.
Be one of the first to reply to this post!