Could somebody explain to me how the ereg_replace function works?
For as for as I understand it replaces strings by a different string (as
explained on the php site) but what I don't understand is how the
following line creates "real" links:
$Content = ereg_replace("[[:alpha:]]+://[^<>[:space:]]+[[:alnum:]/]",
"<a href=\"\\0\" target=\"_blank\">\\0</a>", $Content);
How does this work? Where is the alpha, space, alnum and \\0 stuff come
from?
The main reason why I ask this is because I want to search in a string
for strings like "[QUOTE]" and/or "[/QUOTE]" and replace these with html
tags but for some reason it starts doing realy weird stuff :-)
Cheers
Prodoc
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php