note 26512 added to function.explode

From: Date: Sat, 02 Nov 2002 02:47:56 +0000
Subject: note 26512 added to function.explode
Groups: php.notes 
Request: Send a blank email to php-notes+get-38895@lists.php.net to get a copy of this message
any one use the limit parameter of explode(). It doesnt seem to limit anything. It still splits up the whole string. I just want to get the first 10 words of a string. $strArr = explode(" ",$str,10) This doesnt work. It returns the whole string as an array. I just want 10 words of the string. -- http://www.php.net/manual/en/function.explode.php http://master.php.net/manage/user-notes.php?action=edit+26512 http://master.php.net/manage/user-notes.php?action=delete+26512 http://master.php.net/manage/user-notes.php?action=reject+26512

« previous php.notes (#38895) next »