Dumping query results into a file on the client side.

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
User avatar
AnarKy
Forum Contributor
Posts: 119
Joined: Tue Nov 02, 2004 1:49 am
Location: South Africa

Dumping query results into a file on the client side.

Post by AnarKy »

Hi all,

I have a query that I am displaying in a table on a php page,
I need the ability to dump these results into a file on the client side.

I know how to get the information into a file,
but wont this file be on the server machine?

Does anybody know how to let the user select
the name and location of the file and how to write to the file at that
location on the client machine?

I don’t know if I am posting this in the right place.
Any help would be really appreciated.
Thanks.
kettle_drum
DevNet Resident
Posts: 1150
Joined: Sun Jul 20, 2003 9:25 pm
Location: West Yorkshire, England

Post by kettle_drum »

Search the forums for "forcing downloads". You will have to create the file on the server and then force the user to download it, you cant just put it on their computer.
User avatar
AnarKy
Forum Contributor
Posts: 119
Joined: Tue Nov 02, 2004 1:49 am
Location: South Africa

Thanks.

Post by AnarKy »

Thank you,

It worked fine. Would never have thought of that.
:P
Post Reply