On Tue, 25 Sep 2001 09:49, Devon wrote:
> I am pulling down data from a switch which looks like
>
> Port 1, 33889029532
> Port 2, 0
> Port 3, 135852
> Port 4, 6652941243
> etc etc
>
> I need to know if it is possible with PHP to write a script that will
> pull the individual lines of this text file and store them into a mysql
> database line by line.
>
> Cheers

Yes - have a look at the filesystem functions to get the lines of the 
file; you could use fopen()/fgets() to return a line at a time or even 
just file() to return all lines as elements of an array.

-- 
David Robley      Techno-JoaT, Web Maintainer, Mail List Admin, etc
CENTRE FOR INJURY STUDIES      Flinders University, SOUTH AUSTRALIA  

   Killer Rabbit's Motto: "Lettuce Prey."

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to