Bug #9807 Updated: ereg_replace returns "Warning: Invalid content of \{\}"
| From: | derick@php.net | Date: | Sat, 28 Apr 2001 19:42:12 +0000 |
| Subject: | Bug #9807 Updated: ereg_replace returns "Warning: Invalid content of \{\}" | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-52775@lists.php.net to get a copy of this message | ||
ID: 9807
Updated by: derick
Reported By: ppavlovic@mail.com
Old-Status: Feedback
Status: Closed
Bug Type: *Function Specific
PHP Version: 4.0.1
Assigned To:
Comments:
Works fine for me too.
If this problem persists with PHP 4.0.5 which
will be released next week, please reopen this report.
Derick
Previous Comments:
---------------------------------------------------------------------------
[2001-03-29 05:54:15] stas@php.net
Works for me in 4.0.4. Please re-check with latest version
and if it still happens, please supply values of all
ereg_replace arguments.
---------------------------------------------------------------------------
[2001-03-17 10:09:10] ppavlovic@mail.com
I also encountered this problem. I called ereg_replace from function such as this:
function replace_var($var, $replacement, $v)
{
return ereg_replace("{$var}", htmlspecialchars($replacement), $v);
}
Call to this function was
$form = replace_var("MODEL", $model, $form);
$form is piece of HTML, and MODEL is template variable defined in HTML code like {MODEL}
$var is passed to my replace_var function as is.
---------------------------------------------------------------------------
ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=9807&edit=2