![]() |
PHP newbie question
I'm searching for the code to batch import stuff into a MySQL db, can't find shit.
Example: abc zyx qwe asd Each on a seperate line, from a HTML form submit. Any help? :winkwink: |
Dunno really what you need, but you could use $HTTP_POST_VARS or $HTTP_GET_VARS depending on your form action, then process the array (while) and simple INSERT into db?:)
|
batch import: http://sunsite.mff.cuni.cz/MIRRORS/f...atch_mode.html
the example is not clear in regards to mysql subject |
if its a html submit use a loop, otherwise you can use a txt file and then import into mysql.
|
Quote:
|
something like:
Code:
$txt_array = file('/path/to/file.txt'); Can't you just format your text file like how the table is formatted and run something like: >load data infile ..... -- search good for "load data in file" -- that'd be the fastest and easiest if possible. |
All times are GMT -7. The time now is 05:18 AM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123