Posted by J.O. Aho on 08/05/06 04:09
Shooter wrote:
> I have a colleague who's web designer has gone MIA. He set up a process on
> her hosting account to allow her to download a .CSV membership roster and
> dump it in to an FTP folder. The website would automatically update/replace
> the online roster with the new/updated data. I'm assuming that something
> triggered a MYSQLIMPORT command, but I noticed that she had CRON turned off
> on her control panel so presumably he used another method to make this work.
> Anyone have any suggestions on the best or easiest way to allow her to dump
> a file somewhere and have her mySQL database update the info with any
> new/changed information?
use a while loop that fetches each line in the database and writes it to a
file at the same time in the csv format.
Check
http://www.php.net/manual/en/function.mysql-fetch-array.php
http://www.php.net/manual/en/function.fwrite.php
//Aho
Navigation:
[Reply to this message]
|