#40219 [Opn->Bgs]: end of regexp delimiter has changed to ^
| From: | tony2001@php.net | Date: | Wed, 24 Jan 2007 15:20:58 +0000 |
| Subject: | #40219 [Opn->Bgs]: end of regexp delimiter has changed to ^ | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-107982@lists.php.net to get a copy of this message | ||
ID: 40219
Updated by: tony2001@php.net
Reported By: oliver dot christen at camptocamp dot com
-Status: Open
+Status: Bogus
Bug Type: Regexps related
Operating System: windows server 2003
PHP Version: 5.2.0
New Comment:
Sorry, but your problem does not imply a bug in PHP itself. For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system
is not the
appropriate forum for asking support questions. Due to the volume
of reports we can not explain in detail here why your report is not
a bug. The support channels will be able to provide an explanation
for you.
Thank you for your interest in PHP.
Previous Comments:
------------------------------------------------------------------------
[2007-01-24 15:18:16] user at devnull dot org
Read the documentation, you need delimiters around the expression.
Since ^ is the first character its making that the delimiter.
/^(.+)$/ works.
------------------------------------------------------------------------
[2007-01-24 15:08:15] oliver dot christen at camptocamp dot com
Description:
------------
when using preg_match, the end delimiter of regexp expression is now
expected to be ^, breaking all compability.
shouldnt the end delimiter be '$' ?
Reproduce code:
---------------
preg_match ("^(.+)$", 'foo', $regs);
print_r($regs);
Expected result:
----------------
Array
(
[0] => foo
[1] => foo
)
Actual result:
--------------
Warning: preg_match() [function.preg-match]: No ending delimiter '^'
found in C:\[..cut..]
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=40219&edit=1