ereg_replace and \0

From: Date: Tue, 06 Mar 2001 13:05:03 +0000
Subject: ereg_replace and \0
Groups: php.dev 
Request: Send a blank email to php-dev+get-48031@lists.php.net to get a copy of this message
I don't know if this is a bug, but maybe someone has come accross this issue before. I was trying to use ereg_replace to insert \0 (character \ + character 0) into a string, but I was not able to do it since \0 has special meaning in the regex replacement string. The real problem is that if I try \\0 in the replacement string ("\\\\0" in PHP code) I get \\0 inserted into the string, insted of expected \0. Is there a way around this, or am I just missing something. Edin

« previous php.dev (#48031) next »