Re: [PHP] Parsing Text File

2002-06-15 Thread Analysis & Solutions
> 403 -770 -4904 ,CALGARY,AB,CAN,T2,Y,Y,Apr 29 2002 > 12:00:00:000AM,I,GMT-0700,, Untested, off the top of my head, code... $pointer = fopen('./file.csv', 'r'); while ( $Data = fgetcsv($pointer, 500) ) { # Do what you need, for example... echo 'Their city is: ' . $Data[1]; } --Dan --

Re[2]: [PHP] Parsing Text File

2002-06-15 Thread Stuart Dallas
On Saturday, June 15, 2002 at 9:05:40 PM, Nathan Taylor wrote: > $open = fopen("file.txt","r+"); > while($contents = fgets($open)) { > $line_array[$x] = $contents; > $x++; > } ?>> This wheel exists: http://www.php.net/file -- Stuart -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Parsing Text File

2002-06-15 Thread Nathan Taylor
you can use an explode statement to get both area code and main number seperated. - Original Message - From: Jason D. Williard Sent: Saturday, June 15, 2002 1:28 PM To: [EMAIL PROTECTED] Subject: [PHP] Parsing Text File I am trying to input data from a text file into a MySQL database and w

[PHP] Parsing Text File

2002-06-15 Thread Jason D. Williard
I am trying to input data from a text file into a MySQL database and would like to be able to input the data using a single script. What's the easiest way to parse a line, such as below, and turn it into variables to be placed in the database. While I can simply place the data in by importing fr

Re: [PHP] Parsing text file and dividing column into three...PLEASE help :)

2001-09-20 Thread Jeff Lewis
t would be the best way to do this? Jeff - Original Message - From: "* R&zE:" <[EMAIL PROTECTED]> To: "Jeff Lewis" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Thursday, September 20, 2001 12:16 PM Subject: Re: [PHP] Parsing text file and dividi

Re: [PHP] Parsing text file and dividing column into three...PLEASE help :)

2001-09-20 Thread
From: Jeff Lewis <[EMAIL PROTECTED]> Date: Thu, Sep 20, 2001 at 11:59:32AM -0400 Message-ID: <013e01c141ed$3d51f340$76a1a8c0@LEWISJCIT> Subject: [PHP] Parsing text file and dividing column into three...PLEASE help :) > I have a very large text file that is set up like so: It

[PHP] Parsing text file and dividing column into three...PLEASE help :)

2001-09-20 Thread Jeff Lewis
I have a very large text file that is set up like so: It contains some smaller columns but one HUGE one that contains the body of a resume. I am looking for help on processing this file. What I need to do is convert the final column into three columns. Each column can have no more than 4000