Last modified: 2014-06-23 16:06:59 UTC
If the first three characters on a line are --> doing Show preview takes the browser to a 400 Bad Request page. On MediaWiki MediaWiki 1.21.1 and PHP 5.3.22 (cgi-fcgi).
Thanks for taking the time to report this! I've tried on https://test2.wikipedia.org/wiki/Bug49273 and cannot reproduce the problem. Do you have a specific testcase? Is this on a publicly accessible Mediawiki installation (URL?)?
http://www.sdiy.info
Confirming with account testing1 (password is the same without the 1) on http://www.sdiy.info/w/index.php?title=Foo&action=submit JAVASCRIPT CONSOLE OUTPUT: Error: The character encoding of the HTML document was not declared. The document will render with garbled text in some browser configurations if the document contains characters from outside the US-ASCII range. The character encoding of the page must be declared in the document or in the transfer protocol. Source File: http://www.sdiy.info/w/index.php?title=Foo&action=submit Line: 0 Could you please check your PHP error log? See http://www.mediawiki.org/wiki/Manual:How_to_debug Also see explanation in http://stackoverflow.com/questions/11633162/character-encoding-not-declared-in-html-document why this potentially happens.
There is no entry in the PHP error log for when it happens.
Turns out it only needs -- at the start of a line.
The site host tells me it was caused by ModSecurity.
Ah, thanks for sharing the reason, and glad you found out! Closing as INVALID here as there's not much that can be done about it in the MediaWiki code.