Page 1 of 1

separating.

Posted: Tue Jul 30, 2002 6:25 pm
by cheatboy00
i know i knwo i am an idoit .... but i can seem to find out how to start this... i'm having a memory block...

anyway i have a $var and it contains different values like so...

$var = "stuff,i,we,world";

and as you can see each valuse is separated by a comma ... so i wanted to know how i can separate each of those values into an array....


stupid memory block.

Posted: Tue Jul 30, 2002 6:53 pm
by volka
II. Array Functions -> explode->

Code: Select all

$var = "stuff,i,we,world";
$arr = explode(',', $var);

Posted: Tue Jul 30, 2002 7:04 pm
by cheatboy00
sweet thanks