Why not provide a form button save the data? The action method for that form need no involve the Arduino at all. Execute a PHP script (or cgi or asp or whatever your comfortable with) that collects data from the (hidden, if necessary) fields on the form.

It's most straightforward to send the data as a file in response to a GET request. There are plenty of web server examples to start from, some with SD card support. The easiest way is to read the file a byte at a time and send it to the network.

You can force a browser to download a resource instead of displaying it by including a "content disposition" header in the response headers, after the content-type header:

So, find the place where the web server example is sending the Content-Type and add similar code to send the Content-Disposition. Then send your file, a byte at a time, and it will show up on the browser side as a downloaded file.

That's true, Paul, I believe there is a thread documenting the performance cost of the underlying packet-per-call approach that the library uses elsewhere on the forums.

Having said that, every web server example for Arduino I have seen posted here does it one byte at a time, and it would be unfortunate for the OP to be left with the impression he has to work out a fully buffered implementation as part of his first project. Most people seem to find the performance acceptable, however it looks on a network monitor.

it would be unfortunate for the OP to be left with the impression he has to work out a fully buffered implementation as part of his first project.

True, but there are methods for reading more than one character at a time from the SD card, and there are methods for sending more than one character at a time to the client. It really is very little more work to considerably improve the performance.

One extra line of code to declare the buffer, and one extra argument on the read() and print() calls.