Module:InterwikiTable/doc
| This module is rated as beta. It is considered ready for widespread use, but as it is still relatively new, it should be applied with some caution to ensure results are as expected. |
This is a table of sites containing data about the interwiki prefixes of various Wikimedia sites.
Usage
The module cannot be accessed directly from #invoke. It should be loaded from another Lua module using mw.loadData, like this:
local interwiki_table = mw.loadData('Module:InterwikiTable')
Table fields
The table is made up of subtables for each interwiki destination. For example, interwiki_table.wikipedia points to the entry for Wikipedia. Entries usually correspond to a Wikimedia site, but not always. For example, both the "rev" and "mediawiki" subtables point to mediawiki.org.
Each subtable has five fields:
domain- The base domain name of the website, without any language codes.domain_primary- Whether this is the primary entry for the domain.iw_prefix- A table of valid interwiki prefixes for the site. See Help:Interwiki linking.title_prefix- The text between the domain name and the project's article titles.takes_lang_prefix- Whether the project has separate subdomains for different languages, e.g. es.wikipedia.org.
Examples
interwiki_table.wikipedia.domain→ "wikipedia.org"interwiki_table.wikiversity.domain_primary→ trueinterwiki_table.mediawiki.iw_prefix[1]→ "mw"interwiki_table.wikibooks.title_prefix→ "/wiki/"interwiki_table.meta.takes_lang_prefix→ false
See also
Content Disclaimer
Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.
- The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
- There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
- It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
- Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
- Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.