틀:CURRENTCONTENTLANGUAGE: 두 판 사이의 차이

Revi HQ
내용 추가됨 내용 삭제됨
(creation of a sort of current content language)
(차이 없음)

2013년 10월 29일 (화) 07:16 판

This template returns the "content language" of the current page; more precisely it checks if the current title ends with a language code, and if it is the case it returns this language code, else "en" for English.

Examples:

  • on "Foo/bar", this template returns "en";
  • on "Foo/bar/hu", this template return "hu".

This template takes no argument, and acts as a magic word. If such a magic word is created in MediaWiki, this template could be deleted. Note that the definition of "content language" here is broader than the (page-specific) content language in MediaWiki, which can currently only be set by the Translate extension or some very special pages.