View Single Post
  #5 (permalink)  
Old 12-30-03, 10:00 PM
blaw's Avatar
blaw blaw is offline
Junior Code Guru
 
Join Date: Dec 2003
Location: Vancouver, BC, Canada
Posts: 550
Thanks: 0
Thanked 0 Times in 0 Posts
Hi there,

Do you mean the second row may contain a different number of columns from the first one? All rows in a CSV file should contain the same number of columns, though.

Anyway, if you want the second row (in the file), then you fetch it:

PHP Code:

$num_seond_row explode(','$a_lines[1]); 

If the third, change $a_lines[1] to $a_lines[2], and so on. If you want them all, you can loop it.

In regards to the database insertion, I do not quite understand what you are trying to do.

[quote=tia]
I would like to be able to display in a table format
[quote]

I thought you wanted to display, not store, the values in HTML, not database, table...

[EDITED]
Typo found, really stupid one... =)
__________________
Blavv =|
Reply With Quote