0

I'm using the following PHP code, which opens a 'Save as' file dialog:

$filename = "employeedetails.csv";
            header('Content-type: application/csv');
            header('Content-Disposition: attachment; filename=' . $filename);

When I execute this code, the 'save as' window appears in its maximized form.

How can I reduce/increase the size of this window?

Ruchir Sharma
  • 819
  • 1
  • 10
  • 18

1 Answers1

2

The dialog box is being created by the user's (cleint-side) operating system, so I doubt that there is anything that you can do about it.

Unless, that is, you also have some JS on the client side which you can use to fetch the file then display its own dialog

Mawg says reinstate Monica
  • 38,334
  • 103
  • 306
  • 551
  • Okay. I was wondering whether any changes in 'header' are possible, related to window size.... – Ruchir Sharma Jan 28 '15 at 09:01
  • Noe at all. It is entirely the choice of the client side program (normally, but not always, a browser) and, depending upon what it chooses to to do, the operating system on which it is running. For instance, I can easily code a C program to invoke your PHP, receive the file and store it in a folder named by the current date, with no browser and no "save as" dialog. – Mawg says reinstate Monica Jan 28 '15 at 09:39