Importing CSV data
| From: | Chris Payne | Date: | Sun, 24 Aug 2003 18:37:58 +0000 |
| Subject: | Importing CSV data | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-30077@lists.php.net to get a copy of this message | ||
Hi there everyone,
I have a database with email addresses from people who sign up for a newsletter on my website. Now,
I have a utility i've written where they can save the addresses as a CSV file on their computer
if they are logged in and the admin. What I would love to know, is how can I reserve this? What I
mean is, if there is a CSV file with a single field (EMail) i'd like to be able to insert the
data into the database from a file which would be selected from the admins computers.
I can select a file from the computer no problem, what i'm not sure how to do is to go through
the CSV file, and import the EMail addresses into a record of their own (IE: id1,id2,id3 rather than
all in 1 row)).
Any help / code tips would be REALLY appreciated :-)
Regards
Chris