So basically, I'm working on a script where the administrator can add email addresses line by line in a text area, and when he's finished, the script will add each line to a new row in the database.
When I say a Text Area, I mean a multiline text box.
For example, let's take this input:
The administrator can add as many email addresses as he wants as long as he adds each email address in a new line.
I want to use the PHP explode function:
array explode ( string $delimiter , string $string [, int $limit ] ) //Returns an array of strings, each of which is a substring of string formed by splitting it on boundaries formed by the string delimiter .
The delimiter is the boundary string which I presume means that it is the thing that separates each line / each record. So what would the delimiter be for new line?
Thanks for your help!