Reply to Re: using php to move rows from text file into mysql table

Your name:

Reply:


Posted by Rik on 06/19/07 21:30

On Tue, 19 Jun 2007 23:03:45 +0200, mantrid <ian.dandav@virgin.net> wrote:

> Hello
> Can anyone point me in the right direction for the way to read a text
> file a
> line at a time and separate the fields on that line and use them as data
> in
> an INSERT to add a record to a mysql table. Then read the second line in
> text file and repeat.
>

Worst case: fgets() & explode()/split(), but depending on the format
fscanf() or even the great fgetcsv() can be your friends.
--
Rik Wasmus

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация