Board index   FAQ   Search  
Register  Login
Board index PHP PHP General

save the result of a query in a .txt file

General discussions related to php

Moderators: macek, egami, gesf

save the result of a query in a .txt file

Postby tufi » Wed Mar 05, 2003 2:28 am

Hi,
I would like to know how I can save the result of a query in a new .txt file. How can I do this with php code?
Thank's for helping me.
tufi
New php-forum User
New php-forum User
 
Posts: 2
Joined: Wed Mar 05, 2003 2:20 am

Postby *JaH* » Wed Mar 05, 2003 6:21 am

with fopen() you can open a file for reading/writing
with fwrite() you can write the query into yur txt-file...

use a while() or foreach() to read through the whole query_result-array
*JaH*
New php-forum User
New php-forum User
 
Posts: 80
Joined: Fri Jan 31, 2003 4:18 pm


Return to PHP General

Who is online

Users browsing this forum: No registered users and 2 guests

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.

cron