Re: newbie array question

From: Date: Tue, 13 Aug 2002 19:46:39 +0000
Subject: Re: newbie array question
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-112426@lists.php.net to get a copy of this message
Op dinsdag 13 augustus 2002 20:50, schreef Alexander Ross: > If I have a string variable that is already of the form > ('item','item2','item3') [including the parens and quotes in > the string], > is there an easy way to change that variable into an array?? > Array($var) doesn't work. Thanks <? $var="('item1','item2','item3')"; $array=explode(',',str_replace(array('(',')','\''),'',$var)); ?>

« previous php.general (#112426) next »