0

I am trying to use my terminal to download the xls file from this link https://www.tase.co.il/_layouts/Tase/ManagementPages/ExcelExport.aspx?sn=none&action=1&SubAction=0&GridId=33&CurGuid={26F9CCE6-D184-43C6-BAB9-CF7848987BFF}&ExportType=1

I made sure the link is good by open the link with chrome and the "download xls file" window shows up

I tried wget --no-check-certificate https://www.tase.co.il/_layouts/Tase/ManagementPages/ExcelExport.aspx?sn=none&action=1&SubAction=0&GridId=33&CurGuid={26F9CCE6-D184-43C6-BAB9-CF7848987BFF}&ExportType=1

but without any success

the end point is to create cronjob that will download that latest file from this link and put it in a folder /home/vm1/"dropfilehere" when the xls file name - has the date and time of download

1
  • 3
    Have you tried quoting the URL?
    – danzel
    Apr 25 '18 at 21:05
0

Your URL contains several characters that bash considers as "special": ?, &, '{' and '}'. You may either make these characters non-special with the \ prefix:

https://www.tase.co.il/_layouts/Tase/ManagementPages/ExcelExport.aspx\?sn=none\&action=1\&SubAction=0\&GridId=33\&CurGuid=\{26F9CCE6-D184-43C6-BAB9-CF7848987BFF\}\&ExportType=1

or, place the whole URL inside '' quotes to disable shell interpretation:

'https://www.tase.co.il/_layouts/Tase/ManagementPages/ExcelExport.aspx?sn=none&action=1&SubAction=0&GridId=33&CurGuid={26F9CCE6-D184-43C6-BAB9-CF7848987BFF}&ExportType=1'

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.