Quote:
Originally posted by annams
No url is sent to the usenet posting. This was a problem present in the older version. Can you please provide a fix.
|
Here is a fix (within the remove_bb_code subroutine), replace this:
PHP Code:
$text =~ s/\[url=(\")?//ig; $text =~ s/(\")?\](.)+\[\/url\]//gi; # url
$text =~ s/\[email=(\")?//ig; $text =~ s/(\")?\](.)+\[\/email\]//gi; # email
with this:
PHP Code:
$text =~ s/\[url(=)?(\")?//ig; $text =~ s/(\")?\](.+)\[\/url\]/ $2/gi; # url
$text =~ s/\[email(=)?(\")?//ig; $text =~ s/(\")?\](.+)\[\/email\]/ $2/gi; # email
The probelm was that it didn't recognize the url code when it was like: [ url ]
http://www.gilby.com [ /url ]
I also made it so that any internal text that is in the url code is not removed, so if I had [ url="http://www.gilby.com" ] My Site [ /url ], it would replace it with
http://www.gilby.com My Site. Still not perfect, but no text is lost.