PHP 4.0 Bug #8355 Updated: split() and explode() only accepts 2 parameters
| From: | sniper@php.net | Date: | Fri, 22 Dec 2000 00:56:48 +0000 |
| Subject: | PHP 4.0 Bug #8355 Updated: split() and explode() only accepts 2 parameters | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-42100@lists.php.net to get a copy of this message | ||
ID: 8355
Updated by: sniper
Reported By: webbox@hotmail.com
Status: Closed
Bug Type: *Regular Expressions
Assigned To:
Comments:
I added a note about the third argument into explode() documentation.
--Jani
Previous Comments:
---------------------------------------------------------------------------
[2000-12-21 14:44:32] hholzgra@php.net
third parameter to explode() was added in 4.0.1
third parameter to split() has been there from the start in php 4
---------------------------------------------------------------------------
[2000-12-21 10:53:48] webbox@hotmail.com
The optional limit parameter produces the following error messages when given to the functios
explode() and split():
Warning: Wrong parameter count for explode() in path/to/file.php on line xxx
Warning: unexpected regex error (13) in
path/to/file.php on line xxx
The PHP code I executed was
list ($t1, $t2, $t3) = explode ($find, $string, 3);
list ($t1, $t2, $t3) = split ($find, $string, 3);
---------------------------------------------------------------------------
Full Bug description available at: http://bugs.php.net/?id=8355