|
-
Still Alive
PHP Script to save output to a file?
I built a PHP web app that generates some complicated text output. I now need to change the app to be able to save that output to a file.
I have no idea how to do this. I've messed with the header but that doesnt do what I need. I need to save just a specific section of the PHP text output.
Any thoughts? Or point me in the right direction?
||Intel Dual-Core 1.8 GHz||GIGABYTE GA-965P-DS3||EVGA GeForce 8600GTS||
||G.SKILL 2GB||Seagate Barracuda 250GB||PHILIPS 20X DVD±R||COOLER MASTER Centurion 5||
||A64 3000+||Chaintech SK8T800|Radeon 9800 Pro||
||1 gig PC2700||WD 80gig 7200||BenQ 1620 16x4x40x24||XDreamer II||
-
om nom nom
-
Still Alive
will this work to save a file on to the user's remote PC?
Basically I would like to have a "Save As" button.
||Intel Dual-Core 1.8 GHz||GIGABYTE GA-965P-DS3||EVGA GeForce 8600GTS||
||G.SKILL 2GB||Seagate Barracuda 250GB||PHILIPS 20X DVD±R||COOLER MASTER Centurion 5||
||A64 3000+||Chaintech SK8T800|Radeon 9800 Pro||
||1 gig PC2700||WD 80gig 7200||BenQ 1620 16x4x40x24||XDreamer II||
-
om nom nom
oh, i believe this will only save on the server.
http://www.thescripts.com/forum/thread623560.html
Last edited by JDC; 04-27-2007 at 12:52 PM.
-
Still Alive
Hmm Im not sure how to implement that with what I'm trying to do.
Right now I have all of my desired out put in a string $fileOutput. I'd like the user to be able to save the contents of that string into a text file on their PC.
Will using the header allow me to do that?
||Intel Dual-Core 1.8 GHz||GIGABYTE GA-965P-DS3||EVGA GeForce 8600GTS||
||G.SKILL 2GB||Seagate Barracuda 250GB||PHILIPS 20X DVD±R||COOLER MASTER Centurion 5||
||A64 3000+||Chaintech SK8T800|Radeon 9800 Pro||
||1 gig PC2700||WD 80gig 7200||BenQ 1620 16x4x40x24||XDreamer II||
-
om nom nom
what I've done with Coldfusion is to have a link or button point to a seperate page that would handle the output. Using Coldfusion I set the content type and header, then output.
I think the only downside is that a blank page is opened along with the save as dialog box.
But it seems like setting the header is the way to go.
-
What you can do is this:
Make a folder on your server, write the file to that folder. When the script is done running, output a link to the dir/filename for the user to click on and download that file.
I did this exact thing at work a few weeks ago. If you need an example of how it's done, email me: [email protected]
-
Still Alive
I emailed you aqua.
I've never worked with headers before, any have a good link that could help me out?
||Intel Dual-Core 1.8 GHz||GIGABYTE GA-965P-DS3||EVGA GeForce 8600GTS||
||G.SKILL 2GB||Seagate Barracuda 250GB||PHILIPS 20X DVD±R||COOLER MASTER Centurion 5||
||A64 3000+||Chaintech SK8T800|Radeon 9800 Pro||
||1 gig PC2700||WD 80gig 7200||BenQ 1620 16x4x40x24||XDreamer II||
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|