Hi as above,
I am creating a bulk e-mail sender to send e-shots to our clients.
I have many e-mail address in excel and want to simply copy and paste them into a form textarea field and use php to insert each email address into a database.
Any info or method suggestion appreciated!!
Thanks
Will
Pulling rows from a textbox and insert each row as a new dat
Moderator: General Moderators
- jayshields
- DevNet Resident
- Posts: 1912
- Joined: Mon Aug 22, 2005 12:11 pm
- Location: Leeds/Manchester, England
If someone is looking at this thread for a solution which I would expect was needed before reading the actual question.
Something like this would work:
Something like this would work:
Code: Select all
<?php
$lines = array();
$lines = implode("\n", mysql_real_escape_string($_POST['thetextarea']));
$query = "INSERT INTO `sometable` (`line1`, `line2`, `line3`) VALUES ('$lines[1]', '$lines[2]', '$lines[3]')";
mysql_query($query);
?>