php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #699 explode should not return a 1-element array for an empty string
Submitted: 1998-08-27 11:58 UTC Modified: 1999-06-12 16:16 UTC
From: daniele at orlandi dot com Assigned:
Status: Closed Package: Misbehaving function
PHP Version: 3.0.3 OS: RedHat Linux 5.1
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: daniele at orlandi dot com
New email:
PHP Version: OS:

 

 [1998-08-27 11:58 UTC] daniele at orlandi dot com
$a=explode("",":");
echo count($a);

Prints 1

IMHO, an empty string should explode to a 0-elements array.

Patches

Add a Patch

Pull Requests

Add a Pull Request

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed May 15 06:01:33 2024 UTC