Manual:$wgVersion/ko
File:OOjs UI icon alert-destructive.svg | <translate>
This deprecated feature should no longer be used, but is still available for reasons of backwards compatibility. This feature was deprecated in version <tvar name=ver>1.35.0</tvar>.</translate> |
<translate> General Settings</translate>: $wgVersion | |
---|---|
미디어위키 버전. |
|
<translate> Introduced in version:</translate> | 1.2.0 |
<translate> Deprecated in version:</translate> | 1.35.0 (Gerrit change 481950; git #a5d5ea82) |
<translate> Removed in version:</translate> | <translate> still in use</translate> |
<translate> Allowed values:</translate> | (문자열) |
<translate> Default value:</translate> | Current MediaWiki version - you shouldn't change this! |
<translate> Other settings:</translate> <translate> Alphabetical</translate> | <translate> By function</translate> |
설명
미디어위키의 현재 버전 (예를 들면, "1.41.1"). 이 옵션은 지정할 필요가 없습니다. 내부적으로만 이용됩니다.
MW_VERSION
<td class="mw-version-versionbox" title="<translate nowrap> The latest stable version is <tvar name=1>1.41</tvar></translate>"><translate> MediaWiki version:</translate> |
Starting with MediaWiki 1.35, $wgVersion
is deprecated, and replaced with the MW_VERSION
constant.
It is also available in MediaWiki 1.31.7, 1.33.3 and 1.34.1, though this should not be relied on as its presence is required for some release tools.
$wgVersion
will continue to function the same as before in those versions.
예시
미디어위키 1.19 이후에 동작되는 새 기능을 구현하면서, 그 이전 버전의 하위 호환을 원한다면, 다음과 같이 구성할 수 있습니다:
global $wgVersion;
$oldVersion = version_compare( $wgVersion, '1.18', '<=' );
if ( $oldVersion ) {
# 미디어위키 1.18 이전 버전을 위한 코드
} else {
# 미디어위키 1.19 이후를 위한 코드
}
<translate> MediaWiki version:</translate> |
$oldVersion = version_compare( MW_VERSION, '1.39', '<' );
if ( $oldVersion ) {
# Do stuff for MediaWiki 1.35 - 1.38
} else {
# Do stuff for MediaWiki 1.39+
}
However, it is typically recommended that you use feature detection to see whether the method or class you wish to use is available instead of depending upon raw version strings.
같이 보기
- Special:Version – view the version number of a MediaWiki installation (plus much more information) from the web interface.
- 메뉴얼:업그레이드
- 버전