I'm going mad atm, trying to figure it out?
GHengeveld |
|
---|---|
I think what you're looking for is something like this: $var = preg_replace('/!([^\s])/', '<a href="index.php?e=users&m=details&u=$1">$1</a>', $var); A helpful tool to check your regular expressions is here: http://gskinner.com/RegExr/ By the way, don't you think the @ sign is more appropriate (considering Twitter's usage of this). |