I am trying to write a script that downloads a xlsx file and saves it to the computer. This file doesn't have a specific path and it gets generated after filling a GET
form. There are two submit buttons.
The first one makes a list of results under the form (I can do it). The second one creates a xlsx file and asks where to save it.
<form action="/search" method="get" id="frm-detailedSearchForm">
...
<input type="text" name="publication_date[from]" class="date" tabindex="1" id="frm-detailedSearchForm-publication_date-from" data-nette-rules='[{"op":":filled","rules":[{"op":":pattern","msg":"Nevalidní formát data (dd.mm.rrrr)","arg":"\\d{1,2}\\.\\d{1,2}.\\d{4}"}],"control":"publication_date[from]"}]'>
...
<input type="submit" name="search" class="w-button btn ajax" tabindex="27" value="Search">
<input type="submit" name="export" class="w-button btn" tabindex="28" value="Export">
<input type="hidden" name="do" value="detailedSearchForm-submit"></form>