Manual:$wgSend404Code

From MediaWiki.org
Jump to: navigation, search
This page is a translated version of the page Manual:$wgSend404Code and the translation is 56% complete.

Other languages:
Deutsch • ‎English • ‎español • ‎italiano • ‎日本語 • ‎Lëtzebuergesch • ‎polski • ‎português • ‎português do Brasil • ‎中文
出力: $wgSend404Code
存在しないページに対して、404HTTP状態であることを送信する。
導入されたバージョン: 1.19.0 (r105645)
除去されたバージョン: 使用中
可能な値: 真偽値
既定値: true
他の設定: アルファベット順 | 機能順

詳細

Web servers are supposed to send 404 responses for any not found page. If someone tries to load an article that doesn't exist, MediaWiki sends a 404 status. (Note, editing an article that doesn't exist does not send a 404 status) Some webservers try to intercept 404 responses and give "helpful" 404 response pages, which is quite annoying. Some webservers get the 404 intercepts severely wrong, causing garbage to be output. In either case, you should consider looking for a new web host, but if that's not an option then this setting can work around the issue.

In cases where for technical reasons it is more important for MediaWiki to send the correct status code than for the body to be transmitted intact, this configuration variable is ignored

Changes

Since MediaWiki 1.28MediaWiki 1.28 this setting also affects status code of "action=history" if the page is not there.