2013-08-21, 05:37 PM
Pages: 1 2
2013-08-28, 08:31 AM
(2013-08-15, 10:16 PM)imagey Wrote: [ -> ]Ok i've got it to become click-able, but its loading a page on my forum instead of taking me to the website.
Regular expression: \[url="(.*?)\"](.*?)\[/url\]
Replacement: <a href="\1">\2</a>
If i do a link like[url="www.google.com"]google[/url]
It takes me to http://myforum.com/www.google.com instead of taking me directly to google.com
The syntax for MyCode replacements is $1, $2, $3, etc, not \1, \2, \3. So, try this:
Regular expression: \[url="(.*?)\"](.*?)\[/url\]
Replacement: <a href="$1">$2</a>
2013-09-06, 05:13 PM
2013-09-17, 06:04 PM
(2013-08-15, 10:16 PM)imagey Wrote: [ -> ]Ok i've got it to become click-able, but its loading a page on my forum instead of taking me to the website.
Regular expression: \[url="(.*?)\"](.*?)\[/url\]
Replacement: <a href="\1">\2</a>
If i do a link like[url="www.google.com"]google[/url]
It takes me to http://myforum.com/www.google.com instead of taking me directly to google.com
Since you did not provide a protocol in the URL, it gets resolved relative to the current page. You should almost always use an absolute URL.
www.google.com => http://myforum.com/www.google.com
http://www.google.com => http://www.google.com
Pages: 1 2