Bummer
01-14-2010, 11:25 AM
You probably have a log full of entries about this since I did some experimenting, but I thought I should mention it anyway. On two occasions I've attempted to write a post and gotten the following error, with a difference in the url being quoted. The error occurred when I hit Preview Post. Both were to Wikipedia.
If I remove the url string and tags it is happy. If I add a / to the end of the address it is happy but Wikipedia isn't. I can use a string without a / at the end, but not for a Wikipedia page. Wikipedia main works without a slash, as does adding the /wiki. When I add the actual page name it kicks out the error message. Also, the address portion to upload.wikimedia.org was not in my original quoted address.
----------error follows-----------
Parse error: syntax error, unexpected '[' in /home/dknelson/public_html/forum/includes/ame_bbcode.php(323) : regexp code on line 1
Fatal error: preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Failed evaluating code: ame_match("Post hoc ergo propter hoc (\"http://en.wikipedia.org/wiki/Post_hoc_ergo_propter_hoc\")", "Post hoc ergo propter hoc", 1, "~/wiki/File:[\w\s.,&;\(\)\^%$#@!-]+\\"[\s]class=\\"image\\"[\s]*[\w\s.,&;\(\)\^%$#@!\\"=-]*><img[\s]alt=\\"[\w\s.,&;\(\)\^%$#@!-]*\\"[\s]src=\\"http://upload\.wikimedia\.org/wikipedia/([\w/.,&;\(\)\^%$#@!-]+)\\"~sim", "", $ameinfo) in /home/dknelson/public_html/forum/includes/ame_bbcode.php on line 323
If I remove the url string and tags it is happy. If I add a / to the end of the address it is happy but Wikipedia isn't. I can use a string without a / at the end, but not for a Wikipedia page. Wikipedia main works without a slash, as does adding the /wiki. When I add the actual page name it kicks out the error message. Also, the address portion to upload.wikimedia.org was not in my original quoted address.
----------error follows-----------
Parse error: syntax error, unexpected '[' in /home/dknelson/public_html/forum/includes/ame_bbcode.php(323) : regexp code on line 1
Fatal error: preg_replace() [<a href='function.preg-replace'>function.preg-replace</a>]: Failed evaluating code: ame_match("Post hoc ergo propter hoc (\"http://en.wikipedia.org/wiki/Post_hoc_ergo_propter_hoc\")", "Post hoc ergo propter hoc", 1, "~/wiki/File:[\w\s.,&;\(\)\^%$#@!-]+\\"[\s]class=\\"image\\"[\s]*[\w\s.,&;\(\)\^%$#@!\\"=-]*><img[\s]alt=\\"[\w\s.,&;\(\)\^%$#@!-]*\\"[\s]src=\\"http://upload\.wikimedia\.org/wikipedia/([\w/.,&;\(\)\^%$#@!-]+)\\"~sim", "", $ameinfo) in /home/dknelson/public_html/forum/includes/ame_bbcode.php on line 323