What's the regex to match a square bracket? I'm using
\\] in a pattern in
eregi_replace, but it doesn't seem to be able to find a
\] is correct, but note that PHP itself ALSO has
\ as an escape character, so you might have to use
\\[ (or a different kind of string literal).
<?php $hay = "ab]cd"; echo eregi_replace("\]", "e", $hay); ?>