Re: [PHP] Creating Tab-Delimited Text File

2002-02-07 Thread Analysis and Solutions

"Phillip S. Baker" wrote:
> 
> Greetings All,
> 
> What I want to do is create a tab-delimited text file for download from
> records in a database.

Construct then execute the desired query
   http://www.php.net/manual/en/function.mysql-query.php

Loop through each record, putting each row into an array, then implode the
array with tabs.
   http://www.php.net/manual/en/function.mysql-fetch-row.php
   http://www.php.net/manual/en/function.implode.php

The user can then save the resulting output manually.

Enjoy,

--Dan


-- 
PHP scripts that make your job easier
  http://www.analysisandsolutions.com/code/
 SQL Solution  |  Layout Solution  |  Form Solution
 T H E   A N A L Y S I S   A N D   S O L U T I O N S   C O M P A N Y
 4015 7 Ave, Brooklyn NY 11232v: 718-854-0335f: 718-854-0409

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Creating Tab-Delimited Text File

2002-02-07 Thread Phillip S. Baker

Greetings All,

What I want to do is create a tab-delimited text file for download from 
records in a database.
I am not sure on how to do this.

So what I want to do is as follows.
ON a page a button is clicked.
Script is activated that pulls records from a database.
 From these records a tab-delimited text file is created.
A save dialogue box appears so the user to save the text file to his harddrive.


Thanks

Phillip

Those who give up essential liberty for a little safety,
deserve neither liberty nor safety.
 - Ben Franklin


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php