Dynamic data from user file
| From: | John Patrick | Date: | Tue, 08 Oct 2002 22:15:07 +0000 |
| Subject: | Dynamic data from user file | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-22276@lists.php.net to get a copy of this message | ||
Greetings:
I currently am using the fgetcsv function to read in fields from a
user-defined file. The delimited file is read and displayed just fine.
Firstly, what I'm trying to accomplish: The MySQL database has a table
with about 30 fields. The user-defined file may contain only some of these
fields and in no particular order. I'm trying to achieve a way for the user
to specify what each field is so the insert into MySQL is done correctly.
(An analogy would be a custom import.
The problem I'm having is finding the best way to go about this. I've
been able to read in the data via fgetcsv and dynamically displaying a drop
down box above each field with all possible choices but am unable to create
a way to link the two for each field successfully. Been looking for
solutions as well as trial and error to no avail.
Any suggestions?
-Sean.