php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #14267 Ereg doesn't work on following
Submitted: 2001-11-28 10:14 UTC Modified: 2001-11-28 10:24 UTC
From: tonda at kmoch dot cz Assigned:
Status: Closed Package: *Regular Expressions
PHP Version: 4.0CVS-2001-11-28 OS: Linux Redhat 7.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: tonda at kmoch dot cz
New email:
PHP Version: OS:

 

 [2001-11-28 10:14 UTC] tonda at kmoch dot cz
Dear PHP.net,
   i have this part of script:

if (Ereg("^[a-zA-Z0-9_]{1,8}$", $login)) { ....
.
.

   And this doesn't work correctly on any string containing character 'c'.

P.S. I am using PHP Version 4.0.4pl1
System: Linux porky.devel.redhat.com 2.2.17-8smp #1 SMP Fri Nov 17 16:12:17

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-11-28 10:24 UTC] derick@php.net
This works for me (on both 4.1.0RC3 and 4.2.0dev):

<?php
    $login = "blact";
    if (Ereg("^[a-zA-Z0-9_]{1,8}$", $login)) {
        echo "OK";
    }
?>


output:
OK


Please try the latest RC from www.php.net/~zeev/ and reopen if you still have the problem. However, I don't think this is a bug in PHP, but rather in your code.

Derick
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Tue Dec 07 16:03:34 2021 UTC