note 9550 deleted from explode by jmcastagnetto

From: Date: Sat, 11 Nov 2000 00:34:33 +0000
Subject: note 9550 deleted from explode by jmcastagnetto
Groups: php.notes 
Request: Send a blank email to php-notes+get-7584@lists.php.net to get a copy of this message
I have not been able to use the third, optional parameter successfully. This results in an incorrect number of parameters error. An 'explode' that works correctly breaks as soon as I add a limit, something that would be very useful to me... $mystring = "Joe Bloggs Flat 1, 2 Mornington Place, London"; $info = explode(" ", $mystring, 3); Wouldn't it be nice if this gave an array populated like this... $info[0] "Joe" $info[1] "Bloggs" $info[2] "Flat 1, 2 Mornington Place, London" But I get the error described above :(

« previous php.notes (#7584) next »