Page 1 of 1
subject
Posted: Sat Aug 11, 2007 11:34 pm
by ykarmi
message
Posted: Sun Aug 12, 2007 1:35 am
by infolock
Example of doing 2 of them. Just continue with comma seperation and you should be fine..
Code: Select all
$sql = "INSERT INTO your_table_name_here (field1, field2, field3, field4) VALUES ('Aldora', '349','GER', ' '), ('Amera', '541', 'USA', ' ');
$rst = mysql_query($sql) or die(MySQL_ERROR());
subject
Posted: Sun Aug 12, 2007 12:10 pm
by ykarmi
message
Posted: Sun Aug 12, 2007 1:25 pm
by volka
You could use
explode, (
array_shift,)
array_chunk and
foreach - in this order.
Posted: Mon Aug 13, 2007 6:28 pm
by califdon
What is your data source, a document? What do you mean by "The page is sorted so that every four lines are supposed to be inserted into one row in the database"? Is the page a document, like a text file??