Ok, that first message got a little fux0red: here
I have an admin console setup on a web page so the main page can be edited on the web page itself. I have 'UBB' style formatting (because I'm not the only one uses it, my client updates it).
Up to now, I've been using str_replace for simple tags such as [hr], , etc.
Now I want the user to be able to do colors like this '[color red]text[/color]'. I am having trouble trying to figure out this this regular ereg business. What am I doing wrong?
$string = eregi_replace(
"[color:space:.]",
"<span class=\"color: \0;\">",
$string
);