CINXE.COM
Xem mã nguồn của Mô đun:Lang – Wikipedia tiếng Việt
<!DOCTYPE html> <html class="client-nojs vector-feature-language-in-header-enabled vector-feature-language-in-main-page-header-disabled vector-feature-sticky-header-disabled vector-feature-page-tools-pinned-disabled vector-feature-toc-pinned-clientpref-1 vector-feature-main-menu-pinned-disabled vector-feature-limited-width-clientpref-1 vector-feature-limited-width-content-disabled vector-feature-custom-font-size-clientpref-1 vector-feature-appearance-pinned-clientpref-1 vector-feature-night-mode-enabled skin-theme-clientpref-day vector-toc-not-available" lang="vi" dir="ltr"> <head> <meta charset="UTF-8"> <title>Xem mã nguồn của Mô đun:Lang – Wikipedia tiếng Việt</title> <script>(function(){var className="client-js vector-feature-language-in-header-enabled vector-feature-language-in-main-page-header-disabled vector-feature-sticky-header-disabled vector-feature-page-tools-pinned-disabled vector-feature-toc-pinned-clientpref-1 vector-feature-main-menu-pinned-disabled vector-feature-limited-width-clientpref-1 vector-feature-limited-width-content-disabled vector-feature-custom-font-size-clientpref-1 vector-feature-appearance-pinned-clientpref-1 vector-feature-night-mode-enabled skin-theme-clientpref-day vector-toc-not-available";var cookie=document.cookie.match(/(?:^|; )viwikimwclientpreferences=([^;]+)/);if(cookie){cookie[1].split('%2C').forEach(function(pref){className=className.replace(new RegExp('(^| )'+pref.replace(/-clientpref-\w+$|[^\w-]+/g,'')+'-clientpref-\\w+( |$)'),'$1'+pref+'$2');});}document.documentElement.className=className;}());RLCONF={"wgBreakFrames":true,"wgSeparatorTransformTable":["",""],"wgDigitTransformTable":["",""],"wgDefaultDateFormat": "dmy","wgMonthNames":["","January","February","March","April","May","June","July","August","September","October","November","December"],"wgRequestId":"ea286cb6-9edf-48c4-8642-cfd2bfddc883","wgCanonicalNamespace":"Module","wgCanonicalSpecialPageName":false,"wgNamespaceNumber":828,"wgPageName":"Mô_đun:Lang","wgTitle":"Lang","wgCurRevisionId":71922221,"wgRevisionId":0,"wgArticleId":12428126,"wgIsArticle":false,"wgIsRedirect":false,"wgAction":"edit","wgUserName":null,"wgUserGroups":["*"],"wgCategories":[],"wgPageViewLanguage":"en","wgPageContentLanguage":"en","wgPageContentModel":"Scribunto","wgRelevantPageName":"Mô_đun:Lang","wgRelevantArticleId":12428126,"wgIsProbablyEditable":false,"wgRelevantPageIsProbablyEditable":false,"wgRestrictionEdit":["sysop"],"wgRestrictionMove":["sysop"],"wgNoticeProject":"wikipedia","wgCiteReferencePreviewsActive":false,"wgMediaViewerOnClick":true,"wgMediaViewerEnabledByDefault":true,"wgPopupsFlags":0,"wgVisualEditor":{"pageLanguageCode":"en", "pageLanguageDir":"ltr","pageVariantFallbacks":"en"},"wgMFDisplayWikibaseDescriptions":{"search":true,"watchlist":true,"tagline":true,"nearby":true},"wgWMESchemaEditAttemptStepOversample":false,"wgWMEPageLength":60000,"wgCodeEditorCurrentLanguage":"lua","wgRelatedArticlesCompat":[],"wgCentralAuthMobileDomain":false,"wgEditSubmitButtonLabelPublish":true,"wgULSPosition":"interlanguage","wgULSisCompactLinksEnabled":false,"wgVector2022LanguageInHeader":true,"wgULSisLanguageSelectorEmpty":false,"wgCheckUserClientHintsHeadersJsApi":["brands","architecture","bitness","fullVersionList","mobile","model","platform","platformVersion"],"GEHomepageSuggestedEditsEnableTopics":true,"wgGETopicsMatchModeEnabled":false,"wgGEStructuredTaskRejectionReasonTextInputEnabled":false,"wgGELevelingUpEnabledForUser":false};RLSTATE={"ext.gadget.charinsert-styles":"ready","ext.globalCssJs.user.styles":"ready","site.styles":"ready","user.styles":"ready","ext.globalCssJs.user":"ready","user":"ready","user.options": "loading","ext.codeEditor.styles":"ready","skins.vector.search.codex.styles":"ready","skins.vector.styles":"ready","skins.vector.icons":"ready","mediawiki.ui.button":"ready","ext.charinsert.styles":"ready","ext.wikimediamessages.styles":"ready","ext.visualEditor.desktopArticleTarget.noscript":"ready","ext.uls.interlanguage":"ready","ext.wikimediaBadges":"ready"};RLPAGEMODULES=["ext.codeEditor","ext.scribunto.edit","mediawiki.action.edit.collapsibleFooter","site","mediawiki.page.ready","skins.vector.js","ext.centralNotice.geoIP","ext.charinsert","ext.gadget.did_you_mean","ext.gadget.ReferenceTooltips","ext.gadget.AVIM","ext.gadget.AVIM_portlet","ext.gadget.charinsert","ext.gadget.refToolbar","ext.gadget.wikibugs","ext.gadget.purgetab","ext.gadget.switcher","ext.gadget.AdvancedSiteNotices","ext.urlShortener.toolbar","ext.centralauth.centralautologin","mmv.bootstrap","ext.popups","ext.visualEditor.desktopArticleTarget.init","ext.visualEditor.targetLoader","ext.echo.centralauth", "ext.eventLogging","ext.wikimediaEvents","ext.navigationTiming","ext.uls.interface","ext.cx.eventlogging.campaigns","ext.checkUser.clientHints","wikibase.sidebar.tracking"];</script> <script>(RLQ=window.RLQ||[]).push(function(){mw.loader.impl(function(){return["user.options@12s5i",function($,jQuery,require,module){mw.user.tokens.set({"patrolToken":"+\\","watchToken":"+\\","csrfToken":"+\\"}); }];});});</script> <link rel="stylesheet" href="/w/load.php?lang=vi&modules=ext.charinsert.styles%7Cext.codeEditor.styles%7Cext.uls.interlanguage%7Cext.visualEditor.desktopArticleTarget.noscript%7Cext.wikimediaBadges%7Cext.wikimediamessages.styles%7Cmediawiki.ui.button%7Cskins.vector.icons%2Cstyles%7Cskins.vector.search.codex.styles&only=styles&skin=vector-2022"> <script async="" src="/w/load.php?lang=vi&modules=startup&only=scripts&raw=1&skin=vector-2022"></script> <meta name="ResourceLoaderDynamicStyles" content=""> <link rel="stylesheet" href="/w/load.php?lang=vi&modules=ext.gadget.charinsert-styles&only=styles&skin=vector-2022"> <link rel="stylesheet" href="/w/load.php?lang=vi&modules=site.styles&only=styles&skin=vector-2022"> <meta name="generator" content="MediaWiki 1.44.0-wmf.4"> <meta name="referrer" content="origin"> <meta name="referrer" content="origin-when-cross-origin"> <meta name="robots" content="noindex,nofollow,max-image-preview:standard"> <meta name="format-detection" content="telephone=no"> <meta name="viewport" content="width=1120"> <meta property="og:title" content="Xem mã nguồn của Mô đun:Lang – Wikipedia tiếng Việt"> <meta property="og:type" content="website"> <link rel="preconnect" href="//upload.wikimedia.org"> <link rel="alternate" media="only screen and (max-width: 640px)" href="//vi.m.wikipedia.org/wiki/M%C3%B4_%C4%91un:Lang"> <link rel="apple-touch-icon" href="/static/apple-touch/wikipedia.png"> <link rel="icon" href="/static/favicon/wikipedia.ico"> <link rel="search" type="application/opensearchdescription+xml" href="/w/rest.php/v1/search" title="Wikipedia (vi)"> <link rel="EditURI" type="application/rsd+xml" href="//vi.wikipedia.org/w/api.php?action=rsd"> <link rel="canonical" href="https://vi.wikipedia.org/wiki/M%C3%B4_%C4%91un:Lang"> <link rel="license" href="https://creativecommons.org/licenses/by-sa/4.0/deed.vi"> <link rel="alternate" type="application/atom+xml" title="Nguồn cấp Atom của Wikipedia" href="/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:Thay_%C4%91%E1%BB%95i_g%E1%BA%A7n_%C4%91%C3%A2y&feed=atom"> <link rel="dns-prefetch" href="//login.wikimedia.org"> </head> <body class="codeeditor-loading skin--responsive skin-vector skin-vector-search-vue mediawiki ltr sitedir-ltr mw-hide-empty-elt ns-828 ns-subject page-Mô_đun_Lang rootpage-Mô_đun_Lang skin-vector-2022 action-edit"><a class="mw-jump-link" href="#bodyContent">Bước tới nội dung</a> <div class="vector-header-container"> <header class="vector-header mw-header"> <div class="vector-header-start"> <nav class="vector-main-menu-landmark" aria-label="Trang Web"> <div id="vector-main-menu-dropdown" class="vector-dropdown vector-main-menu-dropdown vector-button-flush-left vector-button-flush-right" > <input type="checkbox" id="vector-main-menu-dropdown-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-vector-main-menu-dropdown" class="vector-dropdown-checkbox " aria-label="Trình đơn chính" > <label id="vector-main-menu-dropdown-label" for="vector-main-menu-dropdown-checkbox" class="vector-dropdown-label cdx-button cdx-button--fake-button cdx-button--fake-button--enabled cdx-button--weight-quiet cdx-button--icon-only " aria-hidden="true" ><span class="vector-icon mw-ui-icon-menu mw-ui-icon-wikimedia-menu"></span> <span class="vector-dropdown-label-text">Trình đơn chính</span> </label> <div class="vector-dropdown-content"> <div id="vector-main-menu-unpinned-container" class="vector-unpinned-container"> <div id="vector-main-menu" class="vector-main-menu vector-pinnable-element"> <div class="vector-pinnable-header vector-main-menu-pinnable-header vector-pinnable-header-unpinned" data-feature-name="main-menu-pinned" data-pinnable-element-id="vector-main-menu" data-pinned-container-id="vector-main-menu-pinned-container" data-unpinned-container-id="vector-main-menu-unpinned-container" > <div class="vector-pinnable-header-label">Trình đơn chính</div> <button class="vector-pinnable-header-toggle-button vector-pinnable-header-pin-button" data-event-name="pinnable-header.vector-main-menu.pin">chuyển sang thanh bên</button> <button class="vector-pinnable-header-toggle-button vector-pinnable-header-unpin-button" data-event-name="pinnable-header.vector-main-menu.unpin">ẩn</button> </div> <div id="p-navigation" class="vector-menu mw-portlet mw-portlet-navigation" > <div class="vector-menu-heading"> Điều hướng </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="n-mainpage-description" class="mw-list-item"><a href="/wiki/Trang_Ch%C3%ADnh" title="Xem trang chính [z]" accesskey="z"><span>Trang Chính</span></a></li><li id="n-wikipedia-featuredcontent" class="mw-list-item"><a href="/wiki/C%E1%BB%95ng_th%C3%B4ng_tin:N%E1%BB%99i_dung_ch%E1%BB%8Dn_l%E1%BB%8Dc"><span>Nội dung chọn lọc</span></a></li><li id="n-randompage" class="mw-list-item"><a href="/wiki/%C4%90%E1%BA%B7c_bi%E1%BB%87t:Ng%E1%BA%ABu_nhi%C3%AAn" title="Xem trang ngẫu nhiên [x]" accesskey="x"><span>Bài viết ngẫu nhiên</span></a></li><li id="n-recentchanges" class="mw-list-item"><a href="/wiki/%C4%90%E1%BA%B7c_bi%E1%BB%87t:Thay_%C4%91%E1%BB%95i_g%E1%BA%A7n_%C4%91%C3%A2y" title="Danh sách thay đổi gần đây trong wiki [r]" accesskey="r"><span>Thay đổi gần đây</span></a></li><li id="n-bug_in_article" class="mw-list-item"><a href="/wiki/Wikipedia:B%C3%A1o_l%E1%BB%97i_b%C3%A0i_vi%E1%BA%BFt"><span>Báo lỗi nội dung</span></a></li> </ul> </div> </div> <div id="p-wikipedia-interaction" class="vector-menu mw-portlet mw-portlet-wikipedia-interaction" > <div class="vector-menu-heading"> Tương tác </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="n-wikipedia-helppage" class="mw-list-item"><a href="/wiki/Wikipedia:S%C3%A1ch_h%C6%B0%E1%BB%9Bng_d%E1%BA%ABn"><span>Hướng dẫn</span></a></li><li id="n-aboutsite" class="mw-list-item"><a href="/wiki/Wikipedia:Gi%E1%BB%9Bi_thi%E1%BB%87u"><span>Giới thiệu Wikipedia</span></a></li><li id="n-portal" class="mw-list-item"><a href="/wiki/Wikipedia:C%E1%BB%99ng_%C4%91%E1%BB%93ng" title="Giới thiệu dự án, cách sử dụng và tìm kiếm thông tin ở đây"><span>Cộng đồng</span></a></li><li id="n-wikipedia-villagepump" class="mw-list-item"><a href="/wiki/Wikipedia:Th%E1%BA%A3o_lu%E1%BA%ADn"><span>Thảo luận chung</span></a></li><li id="n-wikipedia-helpdesk" class="mw-list-item"><a href="/wiki/Wikipedia:Gi%C3%BAp_s%E1%BB%AD_d%E1%BB%A5ng_Wikipedia"><span>Giúp sử dụng</span></a></li><li id="n-contactpage" class="mw-list-item"><a href="//vi.wikipedia.org/wiki/Wikipedia:Liên_lạc"><span>Liên lạc</span></a></li><li id="n-upload" class="mw-list-item"><a href="/wiki/Wikipedia:Tr%C3%ACnh_t%E1%BA%A3i_l%C3%AAn_t%E1%BA%ADp_tin"><span>Tải lên tập tin</span></a></li> </ul> </div> </div> </div> </div> </div> </div> </nav> <a href="/wiki/Trang_Ch%C3%ADnh" class="mw-logo"> <img class="mw-logo-icon" src="/static/images/icons/wikipedia.png" alt="" aria-hidden="true" height="50" width="50"> <span class="mw-logo-container skin-invert"> <img class="mw-logo-wordmark" alt="Wikipedia" src="/static/images/mobile/copyright/wikipedia-wordmark-en.svg" style="width: 7.5em; height: 1.125em;"> <img class="mw-logo-tagline" alt="Bách khoa toàn thư mở" src="/static/images/mobile/copyright/wikipedia-tagline-vi.svg" width="120" height="10" style="width: 7.5em; height: 0.625em;"> </span> </a> </div> <div class="vector-header-end"> <div id="p-search" role="search" class="vector-search-box-vue vector-search-box-collapses vector-search-box-show-thumbnail vector-search-box-auto-expand-width vector-search-box"> <a href="/wiki/%C4%90%E1%BA%B7c_bi%E1%BB%87t:T%C3%ACm_ki%E1%BA%BFm" class="cdx-button cdx-button--fake-button cdx-button--fake-button--enabled cdx-button--weight-quiet cdx-button--icon-only search-toggle" title="Tìm kiếm Wikipedia [f]" accesskey="f"><span class="vector-icon mw-ui-icon-search mw-ui-icon-wikimedia-search"></span> <span>Tìm kiếm</span> </a> <div class="vector-typeahead-search-container"> <div class="cdx-typeahead-search cdx-typeahead-search--show-thumbnail cdx-typeahead-search--auto-expand-width"> <form action="/w/index.php" id="searchform" class="cdx-search-input cdx-search-input--has-end-button"> <div id="simpleSearch" class="cdx-search-input__input-wrapper" data-search-loc="header-moved"> <div class="cdx-text-input cdx-text-input--has-start-icon"> <input class="cdx-text-input__input" type="search" name="search" placeholder="Tìm kiếm trên Wikipedia" aria-label="Tìm kiếm trên Wikipedia" autocapitalize="sentences" title="Tìm kiếm Wikipedia [f]" accesskey="f" id="searchInput" > <span class="cdx-text-input__icon cdx-text-input__start-icon"></span> </div> <input type="hidden" name="title" value="Đặc_biệt:Tìm_kiếm"> </div> <button class="cdx-button cdx-search-input__end-button">Tìm kiếm</button> </form> </div> </div> </div> <nav class="vector-user-links vector-user-links-wide" aria-label="Công cụ cá nhân"> <div class="vector-user-links-main"> <div id="p-vector-user-menu-preferences" class="vector-menu mw-portlet emptyPortlet" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> </ul> </div> </div> <div id="p-vector-user-menu-userpage" class="vector-menu mw-portlet emptyPortlet" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> </ul> </div> </div> <nav class="vector-appearance-landmark" aria-label="Giao diện"> <div id="vector-appearance-dropdown" class="vector-dropdown " title="Change the appearance of the page's font size, width, and color" > <input type="checkbox" id="vector-appearance-dropdown-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-vector-appearance-dropdown" class="vector-dropdown-checkbox " aria-label="Giao diện" > <label id="vector-appearance-dropdown-label" for="vector-appearance-dropdown-checkbox" class="vector-dropdown-label cdx-button cdx-button--fake-button cdx-button--fake-button--enabled cdx-button--weight-quiet cdx-button--icon-only " aria-hidden="true" ><span class="vector-icon mw-ui-icon-appearance mw-ui-icon-wikimedia-appearance"></span> <span class="vector-dropdown-label-text">Giao diện</span> </label> <div class="vector-dropdown-content"> <div id="vector-appearance-unpinned-container" class="vector-unpinned-container"> </div> </div> </div> </nav> <div id="p-vector-user-menu-notifications" class="vector-menu mw-portlet emptyPortlet" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> </ul> </div> </div> <div id="p-vector-user-menu-overflow" class="vector-menu mw-portlet" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="pt-sitesupport-2" class="user-links-collapsible-item mw-list-item user-links-collapsible-item"><a data-mw="interface" href="//donate.wikimedia.org/wiki/Special:FundraiserRedirector?utm_source=donate&utm_medium=sidebar&utm_campaign=C13_vi.wikipedia.org&uselang=vi" class=""><span>Quyên góp</span></a> </li> <li id="pt-createaccount-2" class="user-links-collapsible-item mw-list-item user-links-collapsible-item"><a data-mw="interface" href="/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:M%E1%BB%9F_t%C3%A0i_kho%E1%BA%A3n&returnto=M%C3%B4+%C4%91un%3ALang&returntoquery=action%3Dedit" title="Bạn được khuyến khích mở tài khoản và đăng nhập; tuy nhiên, không bắt buộc phải có tài khoản" class=""><span>Tạo tài khoản</span></a> </li> <li id="pt-login-2" class="user-links-collapsible-item mw-list-item user-links-collapsible-item"><a data-mw="interface" href="/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:%C4%90%C4%83ng_nh%E1%BA%ADp&returnto=M%C3%B4+%C4%91un%3ALang&returntoquery=action%3Dedit" title="Đăng nhập sẽ có lợi hơn, tuy nhiên không bắt buộc. [o]" accesskey="o" class=""><span>Đăng nhập</span></a> </li> </ul> </div> </div> </div> <div id="vector-user-links-dropdown" class="vector-dropdown vector-user-menu vector-button-flush-right vector-user-menu-logged-out" title="Thêm tùy chọn" > <input type="checkbox" id="vector-user-links-dropdown-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-vector-user-links-dropdown" class="vector-dropdown-checkbox " aria-label="Công cụ cá nhân" > <label id="vector-user-links-dropdown-label" for="vector-user-links-dropdown-checkbox" class="vector-dropdown-label cdx-button cdx-button--fake-button cdx-button--fake-button--enabled cdx-button--weight-quiet cdx-button--icon-only " aria-hidden="true" ><span class="vector-icon mw-ui-icon-ellipsis mw-ui-icon-wikimedia-ellipsis"></span> <span class="vector-dropdown-label-text">Công cụ cá nhân</span> </label> <div class="vector-dropdown-content"> <div id="p-personal" class="vector-menu mw-portlet mw-portlet-personal user-links-collapsible-item" title="Bảng chọn thành viên" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="pt-sitesupport" class="user-links-collapsible-item mw-list-item"><a href="//donate.wikimedia.org/wiki/Special:FundraiserRedirector?utm_source=donate&utm_medium=sidebar&utm_campaign=C13_vi.wikipedia.org&uselang=vi"><span>Quyên góp</span></a></li><li id="pt-createaccount" class="user-links-collapsible-item mw-list-item"><a href="/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:M%E1%BB%9F_t%C3%A0i_kho%E1%BA%A3n&returnto=M%C3%B4+%C4%91un%3ALang&returntoquery=action%3Dedit" title="Bạn được khuyến khích mở tài khoản và đăng nhập; tuy nhiên, không bắt buộc phải có tài khoản"><span class="vector-icon mw-ui-icon-userAdd mw-ui-icon-wikimedia-userAdd"></span> <span>Tạo tài khoản</span></a></li><li id="pt-login" class="user-links-collapsible-item mw-list-item"><a href="/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:%C4%90%C4%83ng_nh%E1%BA%ADp&returnto=M%C3%B4+%C4%91un%3ALang&returntoquery=action%3Dedit" title="Đăng nhập sẽ có lợi hơn, tuy nhiên không bắt buộc. [o]" accesskey="o"><span class="vector-icon mw-ui-icon-logIn mw-ui-icon-wikimedia-logIn"></span> <span>Đăng nhập</span></a></li> </ul> </div> </div> <div id="p-user-menu-anon-editor" class="vector-menu mw-portlet mw-portlet-user-menu-anon-editor" > <div class="vector-menu-heading"> Trang dành cho người dùng chưa đăng nhập <a href="/wiki/Tr%E1%BB%A3_gi%C3%BAp:Gi%E1%BB%9Bi_thi%E1%BB%87u" aria-label="Tìm hiểu thêm về sửa đổi"><span>tìm hiểu thêm</span></a> </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="pt-anoncontribs" class="mw-list-item"><a href="/wiki/%C4%90%E1%BA%B7c_bi%E1%BB%87t:%C4%90%C3%B3ng_g%C3%B3p_c%E1%BB%A7a_t%C3%B4i" title="Danh sách các sửa đổi được thực hiện qua địa chỉ IP này [y]" accesskey="y"><span>Đóng góp</span></a></li><li id="pt-anontalk" class="mw-list-item"><a href="/wiki/%C4%90%E1%BA%B7c_bi%E1%BB%87t:Th%E1%BA%A3o_lu%E1%BA%ADn_t%C3%B4i" title="Thảo luận với địa chỉ IP này [n]" accesskey="n"><span>Thảo luận cho địa chỉ IP này</span></a></li> </ul> </div> </div> </div> </div> </nav> </div> </header> </div> <div class="mw-page-container"> <div class="mw-page-container-inner"> <div class="vector-sitenotice-container"> <div id="siteNotice"><!-- CentralNotice --></div> </div> <div class="vector-column-start"> <div class="vector-main-menu-container"> <div id="mw-navigation"> <nav id="mw-panel" class="vector-main-menu-landmark" aria-label="Trang Web"> <div id="vector-main-menu-pinned-container" class="vector-pinned-container"> </div> </nav> </div> </div> </div> <div class="mw-content-container"> <main id="content" class="mw-body"> <header class="mw-body-header vector-page-titlebar"> <h1 id="firstHeading" class="firstHeading mw-first-heading">Xem mã nguồn của Mô đun:Lang</h1> <div id="p-lang-btn" class="vector-dropdown mw-portlet mw-portlet-lang" > <input type="checkbox" id="p-lang-btn-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-p-lang-btn" class="vector-dropdown-checkbox mw-interlanguage-selector" aria-label="Bài viết này chỉ tồn tại bằng ngôn ngữ này. Thêm bài viết cho các ngôn ngữ khác" > <label id="p-lang-btn-label" for="p-lang-btn-checkbox" class="vector-dropdown-label cdx-button cdx-button--fake-button cdx-button--fake-button--enabled cdx-button--weight-quiet cdx-button--action-progressive mw-portlet-lang-heading-0" aria-hidden="true" ><span class="vector-icon mw-ui-icon-language-progressive mw-ui-icon-wikimedia-language-progressive"></span> <span class="vector-dropdown-label-text">Thêm ngôn ngữ</span> </label> <div class="vector-dropdown-content"> <div class="vector-menu-content"> <ul class="vector-menu-content-list"> </ul> <div class="after-portlet after-portlet-lang"><span class="uls-after-portlet-link"></span></div> </div> </div> </div> </header> <div class="vector-page-toolbar"> <div class="vector-page-toolbar-container"> <div id="left-navigation"> <nav aria-label="Không gian tên"> <div id="p-associated-pages" class="vector-menu vector-menu-tabs mw-portlet mw-portlet-associated-pages" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="ca-nstab-module" class="selected vector-tab-noicon mw-list-item"><a href="/wiki/M%C3%B4_%C4%91un:Lang" title="Xem mô đun [c]" accesskey="c"><span>Mô đun</span></a></li><li id="ca-talk" class="vector-tab-noicon mw-list-item"><a href="/wiki/Th%E1%BA%A3o_lu%E1%BA%ADn_M%C3%B4_%C4%91un:Lang" rel="discussion" title="Thảo luận về trang này [t]" accesskey="t"><span>Thảo luận</span></a></li> </ul> </div> </div> <div id="vector-variants-dropdown" class="vector-dropdown emptyPortlet" > <input type="checkbox" id="vector-variants-dropdown-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-vector-variants-dropdown" class="vector-dropdown-checkbox " aria-label="Thay đổi biến thể ngôn ngữ" > <label id="vector-variants-dropdown-label" for="vector-variants-dropdown-checkbox" class="vector-dropdown-label cdx-button cdx-button--fake-button cdx-button--fake-button--enabled cdx-button--weight-quiet" aria-hidden="true" ><span class="vector-dropdown-label-text">English</span> </label> <div class="vector-dropdown-content"> <div id="p-variants" class="vector-menu mw-portlet mw-portlet-variants emptyPortlet" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> </ul> </div> </div> </div> </div> </nav> </div> <div id="right-navigation" class="vector-collapsible"> <nav aria-label="Giao diện"> <div id="p-views" class="vector-menu vector-menu-tabs mw-portlet mw-portlet-views" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="ca-view" class="vector-tab-noicon mw-list-item"><a href="/wiki/M%C3%B4_%C4%91un:Lang"><span>Đọc</span></a></li><li id="ca-viewsource" class="selected vector-tab-noicon mw-list-item"><a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang&action=edit" title="Trang này được khóa. Bạn có thể xem mã nguồn. [e]" accesskey="e"><span>Xem mã nguồn</span></a></li><li id="ca-history" class="vector-tab-noicon mw-list-item"><a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang&action=history" title="Các phiên bản cũ của trang này [h]" accesskey="h"><span>Xem lịch sử</span></a></li> </ul> </div> </div> </nav> <nav class="vector-page-tools-landmark" aria-label="Công cụ trang"> <div id="vector-page-tools-dropdown" class="vector-dropdown vector-page-tools-dropdown" > <input type="checkbox" id="vector-page-tools-dropdown-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-vector-page-tools-dropdown" class="vector-dropdown-checkbox " aria-label="Công cụ" > <label id="vector-page-tools-dropdown-label" for="vector-page-tools-dropdown-checkbox" class="vector-dropdown-label cdx-button cdx-button--fake-button cdx-button--fake-button--enabled cdx-button--weight-quiet" aria-hidden="true" ><span class="vector-dropdown-label-text">Công cụ</span> </label> <div class="vector-dropdown-content"> <div id="vector-page-tools-unpinned-container" class="vector-unpinned-container"> <div id="vector-page-tools" class="vector-page-tools vector-pinnable-element"> <div class="vector-pinnable-header vector-page-tools-pinnable-header vector-pinnable-header-unpinned" data-feature-name="page-tools-pinned" data-pinnable-element-id="vector-page-tools" data-pinned-container-id="vector-page-tools-pinned-container" data-unpinned-container-id="vector-page-tools-unpinned-container" > <div class="vector-pinnable-header-label">Công cụ</div> <button class="vector-pinnable-header-toggle-button vector-pinnable-header-pin-button" data-event-name="pinnable-header.vector-page-tools.pin">chuyển sang thanh bên</button> <button class="vector-pinnable-header-toggle-button vector-pinnable-header-unpin-button" data-event-name="pinnable-header.vector-page-tools.unpin">ẩn</button> </div> <div id="p-cactions" class="vector-menu mw-portlet mw-portlet-cactions emptyPortlet vector-has-collapsible-items" title="Thêm tùy chọn" > <div class="vector-menu-heading"> Tác vụ </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="ca-more-view" class="vector-more-collapsible-item mw-list-item"><a href="/wiki/M%C3%B4_%C4%91un:Lang"><span>Đọc</span></a></li><li id="ca-more-viewsource" class="selected vector-more-collapsible-item mw-list-item"><a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang&action=edit"><span>Xem mã nguồn</span></a></li><li id="ca-more-history" class="vector-more-collapsible-item mw-list-item"><a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang&action=history"><span>Xem lịch sử</span></a></li> </ul> </div> </div> <div id="p-tb" class="vector-menu mw-portlet mw-portlet-tb" > <div class="vector-menu-heading"> Chung </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="t-whatlinkshere" class="mw-list-item"><a href="/wiki/%C4%90%E1%BA%B7c_bi%E1%BB%87t:Li%C3%AAn_k%E1%BA%BFt_%C4%91%E1%BA%BFn_%C4%91%C3%A2y/M%C3%B4_%C4%91un:Lang" title="Các trang liên kết đến đây [j]" accesskey="j"><span>Các liên kết đến đây</span></a></li><li id="t-recentchangeslinked" class="mw-list-item"><a href="/wiki/%C4%90%E1%BA%B7c_bi%E1%BB%87t:Thay_%C4%91%E1%BB%95i_li%C3%AAn_quan/M%C3%B4_%C4%91un:Lang" rel="nofollow" title="Thay đổi gần đây của các trang liên kết đến đây [k]" accesskey="k"><span>Thay đổi liên quan</span></a></li><li id="t-specialpages" class="mw-list-item"><a href="/wiki/%C4%90%E1%BA%B7c_bi%E1%BB%87t:Trang_%C4%91%E1%BA%B7c_bi%E1%BB%87t" title="Một danh sách chứa tất cả trang đặc biệt [q]" accesskey="q"><span>Trang đặc biệt</span></a></li><li id="t-info" class="mw-list-item"><a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang&action=info" title="Thêm chi tiết về trang này"><span>Thông tin trang</span></a></li><li id="t-urlshortener" class="mw-list-item"><a href="/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:UrlShortener&url=https%3A%2F%2Fvi.wikipedia.org%2Fw%2Findex.php%3Ftitle%3DM%25C3%25B4_%25C4%2591un%3ALang%26action%3Dedit"><span>Lấy URL ngắn gọn</span></a></li><li id="t-urlshortener-qrcode" class="mw-list-item"><a href="/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:QrCode&url=https%3A%2F%2Fvi.wikipedia.org%2Fw%2Findex.php%3Ftitle%3DM%25C3%25B4_%25C4%2591un%3ALang%26action%3Dedit"><span>Tải mã QR</span></a></li> </ul> </div> </div> <div id="p-wikibase-otherprojects" class="vector-menu mw-portlet mw-portlet-wikibase-otherprojects" > <div class="vector-menu-heading"> Tại dự án khác </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="t-wikibase" class="wb-otherproject-link wb-otherproject-wikibase-dataitem mw-list-item"><a href="https://www.wikidata.org/wiki/Special:EntityPage/Q42895737" title="Liên kết đến khoản mục kết nối trong kho dữ liệu [g]" accesskey="g"><span>Khoản mục Wikidata</span></a></li> </ul> </div> </div> </div> </div> </div> </div> </nav> </div> </div> </div> <div class="vector-column-end"> <div class="vector-sticky-pinned-container"> <nav class="vector-page-tools-landmark" aria-label="Công cụ trang"> <div id="vector-page-tools-pinned-container" class="vector-pinned-container"> </div> </nav> <nav class="vector-appearance-landmark" aria-label="Giao diện"> <div id="vector-appearance-pinned-container" class="vector-pinned-container"> <div id="vector-appearance" class="vector-appearance vector-pinnable-element"> <div class="vector-pinnable-header vector-appearance-pinnable-header vector-pinnable-header-pinned" data-feature-name="appearance-pinned" data-pinnable-element-id="vector-appearance" data-pinned-container-id="vector-appearance-pinned-container" data-unpinned-container-id="vector-appearance-unpinned-container" > <div class="vector-pinnable-header-label">Giao diện</div> <button class="vector-pinnable-header-toggle-button vector-pinnable-header-pin-button" data-event-name="pinnable-header.vector-appearance.pin">chuyển sang thanh bên</button> <button class="vector-pinnable-header-toggle-button vector-pinnable-header-unpin-button" data-event-name="pinnable-header.vector-appearance.unpin">ẩn</button> </div> </div> </div> </nav> </div> </div> <div id="bodyContent" class="vector-body" aria-labelledby="firstHeading" data-mw-ve-target-container> <div class="vector-body-before-content"> <div class="mw-indicators"> </div> </div> <div id="contentSub"><div id="mw-content-subtitle">← <a href="/wiki/M%C3%B4_%C4%91un:Lang" title="Mô đun:Lang">Mô đun:Lang</a></div></div> <div id="mw-content-text" class="mw-body-content"><p>Bạn không được quyền sửa đổi trang này, vì các lý do sau: </p> <ul class="permissions-errors"><li class="mw-permissionerror-protectedpagetext"><div class="mw-parser-output"><style data-mw-deduplicate="TemplateStyles:r69621137">.mw-parser-output .pptext-whywhat h2{margin-top:1em;border-bottom:0;font-size:130%;font-weight:bold;padding:0.15em}.mw-parser-output .pptext-submit{list-style:none;display:inline;text-align:center}.mw-parser-output .pptext-whywhat{display:flex;flex-wrap:wrap;column-gap:2em}.mw-parser-output .pptext-whywhat>div{flex:1 1 400px}</style><table id="mw-protectedpagetext" class="plainlinks fmbox fmbox-system" role="presentation" style="border-style:none;"><tbody><tr><td class="mbox-text"><table class="plainlinks ombox ombox-protection" role="presentation"><tbody><tr><td class="mbox-image"><span typeof="mw:File"><span><img alt="" src="//upload.wikimedia.org/wikipedia/commons/thumb/1/12/Full-protection-shackle-block.svg/40px-Full-protection-shackle-block.svg.png" decoding="async" width="40" height="40" class="mw-file-element" srcset="//upload.wikimedia.org/wikipedia/commons/thumb/1/12/Full-protection-shackle-block.svg/60px-Full-protection-shackle-block.svg.png 1.5x, //upload.wikimedia.org/wikipedia/commons/thumb/1/12/Full-protection-shackle-block.svg/80px-Full-protection-shackle-block.svg.png 2x" data-file-width="512" data-file-height="512" /></span></span></td><td class="mbox-text" style="font-weight:bold; font-size:130%;">Trang này đang bị <a href="/wiki/Wikipedia:Quy_%C4%91%E1%BB%8Bnh_kh%C3%B3a_trang#full" title="Wikipedia:Quy định khóa trang">khóa</a>, chỉ có các <a href="/wiki/Wikipedia:B%E1%BA%A3o_qu%E1%BA%A3n_vi%C3%AAn" title="Wikipedia:Bảo quản viên">bảo quản viên</a> mới có thể sửa đổi trang.</td></tr></tbody></table> <div class="pptext-whywhat"> <div class="pptext-why"> <div class="mw-heading mw-heading2"><h2 id="Tại_sao_trang_này_bị_khóa?"><span id="T.E1.BA.A1i_sao_trang_n.C3.A0y_b.E1.BB.8B_kh.C3.B3a.3F"></span>Tại sao trang này bị khóa?</h2></div> <ul> <li>Mặc dù bạn có thể sửa đổi hầu hết các trang, tuy nhiên có một số <a href="/wiki/Wikipedia:B%E1%BA%A3n_m%E1%BA%ABu" class="mw-redirect" title="Wikipedia:Bản mẫu">bản mẫu</a> và trang giao diện bị <a href="/wiki/Wikipedia:Kh%C3%B3a_trang#Khóa_hẳn" class="mw-redirect" title="Wikipedia:Khóa trang">khóa hẳn</a> bởi vì chúng được sử dụng rất nhiều. Đôi khi các bài viết cũng được khóa tạm thời vì <a href="/wiki/Wikipedia:B%C3%BAt_chi%E1%BA%BFn" title="Wikipedia:Bút chiến">mâu thuẫn sửa đổi</a>.</li> <li>Lý do cụ thể của việc khóa trang có thể được tìm thấy trong <a class="external text" href="https://vi.wikipedia.org/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:Log&type=protect&page=M%C3%B4+%C4%91un%3ALang">nhật trình khóa</a>. Nếu không có mục nào liên quan trong nhật trình, trang này có thể đã bị <a class="external text" href="https://vi.wikipedia.org/w/index.php?title=%C4%90%E1%BA%B7c_bi%E1%BB%87t:Log&type=move&page=M%C3%B4_%C4%91un:Lang">di chuyển</a> sau khi khóa. </li> </ul> </div> <div class="pptext-what"> <div class="mw-heading mw-heading2"><h2 id="Tôi_có_thể_làm_gì?"><span id="T.C3.B4i_c.C3.B3_th.E1.BB.83_l.C3.A0m_g.C3.AC.3F"></span>Tôi có thể làm gì?</h2></div> <ul> <li> <a href="/wiki/Th%E1%BA%A3o_lu%E1%BA%ADn_M%C3%B4_%C4%91un:Lang" title="Thảo luận Mô đun:Lang">Thảo luận về trang này</a> với người dùng khác.</li> <li> Nếu bạn muốn đổi tên trang đã bị khóa, hãy đề nghị tại <a href="/wiki/Wikipedia:Y%C3%AAu_c%E1%BA%A7u_di_chuy%E1%BB%83n_trang" title="Wikipedia:Yêu cầu di chuyển trang">yêu cầu di chuyển trang</a>.</li> <li> <a href="/wiki/Wikipedia:Y%C3%AAu_c%E1%BA%A7u_kh%C3%B3a_hay_m%E1%BB%9F_kh%C3%B3a_trang" title="Wikipedia:Yêu cầu khóa hay mở khóa trang">Yêu cầu mở khóa</a> trang này.</li> <li> Đây là lần đầu tiên bạn vào Wikipedia? Hãy xem qua trang <a href="/wiki/Wikipedia:Ch%C3%A0o_m%E1%BB%ABng_ng%C6%B0%E1%BB%9Di_m%E1%BB%9Bi_%C4%91%E1%BA%BFn" title="Wikipedia:Chào mừng người mới đến">chào mừng thành viên mới</a> để tìm hiểu thêm làm sao để bắt đầu sửa đổi trên Wikipedia.</li> <li>Nếu bạn nhận ra có sai sót hoặc muốn đề xuất một vài thay đổi đơn giản, không gây tranh cãi, hãy yêu cầu sửa trang bị khóa bằng cách bấm nút bên dưới và làm theo hướng dẫn. Một <a href="/wiki/Wikipedia:B%E1%BA%A3o_qu%E1%BA%A3n_vi%C3%AAn" title="Wikipedia:Bảo quản viên">bảo quản viên</a> sẽ xem xét và thực hiện yêu cầu sửa đổi đó của bạn. Hãy kiểm tra <a href="/wiki/Th%E1%BA%A3o_lu%E1%BA%ADn_M%C3%B4_%C4%91un:Lang" title="Thảo luận Mô đun:Lang">trang thảo luận</a> trước, có thể vấn đề bạn muốn đề xuất đang được bàn luận ở đó.</li> <li class="pptext-submit"><div> <p><span class="plainlinks"><a class="external text" href="https://vi.wikipedia.org/w/index.php?title=Th%E1%BA%A3o_lu%E1%BA%ADn_M%C3%B4_%C4%91un%3ALang&preload=B%E1%BA%A3n+m%E1%BA%ABu%3AY%C3%AAu+c%E1%BA%A7u+s%E1%BB%ADa+trang+kh%C3%B3a%2Fpreload&action=edit&section=new&editintro=B%E1%BA%A3n+m%E1%BA%ABu%3AS%E1%BB%ADa+trang+kh%C3%B3a%2Feditintro&preloadtitle=Y%C3%AAu+c%E1%BA%A7u+s%E1%BB%ADa+trang+b%E1%BB%8B+kh%C3%B3a+h%E1%BA%B3n+ng%C3%A0y+27+th%C3%A1ng+11+n%C4%83m+2024&preloadparams%5B%5D=S%E1%BB%ADa+trang+kh%C3%B3a+h%E1%BA%B3n&preloadparams%5B%5D=M%C3%B4+%C4%91un%3ALang"><span class="mw-ui-button mw-ui-progressive">Yêu cầu sửa trang này</span></a></span> </p> </div></li> <li>Nếu bạn đã viết bất kỳ thứ gì, vui lòng lưu nó tạm thời vào thiết bị của bạn cho đến khi bạn có thể sửa đổi trang này.</li> </ul> </div> </div></td></tr></tbody></table></div></li><li class="mw-permissionerror-globalblocking-blockedtext-range"><b>Your IP address is in a range that has been <a href="https://meta.wikimedia.org/wiki/Special:MyLanguage/Global_blocks" class="extiw" title="m:Special:MyLanguage/Global blocks">blocked on all Wikimedia Foundation wikis</a>.</b> <p>The block was made by <a href="/wiki/Th%C3%A0nh_vi%C3%AAn:Jon_Kolbert" title="Thành viên:Jon Kolbert">Jon Kolbert</a>. The reason given is <i><a href="https://meta.wikimedia.org/wiki/Special:MyLanguage/NOP" class="extiw" title="m:Special:MyLanguage/NOP">Open proxy/Webhost</a>: See the <a href="https://meta.wikimedia.org/wiki/WM:OP/H" class="extiw" title="m:WM:OP/H">help page</a> if you are affected </i>. </p> <ul><li>Start of block: 15:12, ngày 27 tháng 8 năm 2023</li> <li>Expiry of block: 15:12, ngày 27 tháng 8 năm 2028</li></ul> <p>Your current IP address is 8.222.208.146. The blocked range is 8.222.128.0/17. </p><p>Xin hãy cung cấp tất cả các thông tin trên vào thư yêu cầu của bạn. Nếu bạn bị cấm do sự nhầm lẫn, bạn có thể xem thêm thông tin và hướng dẫn tại quy định toàn cục <a href="https://meta.wikimedia.org/wiki/Special:MyLanguage/No_open_proxies" class="extiw" title="m:Special:MyLanguage/No open proxies">Không cho phép các proxy mở</a>. </p> Để thảo luận về vụ cấm này, xin vui lòng <a href="https://meta.wikimedia.org/wiki/Steward_requests/Global" class="extiw" title="m:Steward requests/Global">yêu cầu kiểm tra lại tại Meta-Wiki</a>. You could also send an email to the <a href="https://meta.wikimedia.org/wiki/Special:MyLanguage/Stewards" class="extiw" title="m:Special:MyLanguage/Stewards">stewards</a> <a href="https://meta.wikimedia.org/wiki/Special:MyLanguage/VRT" class="extiw" title="m:Special:MyLanguage/VRT">VRT</a> queue at <kbd>stewards@wikimedia.org</kbd> including all above details.</li></ul><hr /> <div id="viewsourcetext">Bạn vẫn có thể xem và chép xuống mã nguồn của trang này:</div><textarea readonly="" accesskey="," id="wpTextbox1" cols="80" rows="25" style="" class="mw-editfont-monospace" lang="en" dir="ltr" name="wpTextbox1">--[=[ Lua support for the {{lang}}, {{lang-xx}}, and {{transl}} templates and replacement of various supporting templates. ]=] require('strict'); local p = {}; local initial_style_state; -- set by lang_xx_inherit() and lang_xx_italic() local getArgs = require ('Mô đun:Arguments').getArgs; local lang_name_table = mw.loadData ('Mô đun:Language/name/data'); local synonym_table = mw.loadData ('Mô đun:Lang/ISO 639 synonyms'); -- ISO 639-2/639-2T code translation to 639-1 code local lang_data = mw.loadData ('Mô đun:Lang/data'); -- language name override and transliteration tool-tip tables local namespace = mw.title.getCurrentTitle().namespace; -- used for categorization local maint_cats = {}; -- maintenance categories go here local maint_msgs = {}; -- and their messages go here local function isCollective( language_name ) return language_name:find ('[Nn]gôn') or language_name:find ('[Nn]gữ') or language_name:find ('[Tt]hoại') or language_name:find ('languages') end --[[--------------------------< I S _ S E T >------------------------------------------------------------------ Returns true if argument is set; false otherwise. Argument is 'set' when it exists (not nil) or when it is not an empty string. ]] local function is_set( var ) return not (var == nil or var == ''); end --[[--------------------------< I S _ L A T N >---------------------------------------------------------------- Returns true if all of text argument is written using Latn script for letters, numbers and punctuationset; false else. For the purposes of this function, Latn script is characters less control characters from these Unicode 10.0 Character Code Charts: [http://www.unicode.org/charts/PDF/U0000.pdf C0 Controls and Basic Latin] U+0020–U+007E (20 - 7E) + see note about <poem>...</poem> support [http://www.unicode.org/charts/PDF/U0080.pdf C1 Controls and Latin-1 Supplement] U+00A0-U+00AC, U+00C0–U+00FF (C2 A0 - C2 AC, C3 80 - C3 BF: \194\160-\194\172) [http://www.unicode.org/charts/PDF/U0100.pdf Latin Extended-A] U+0100–U+017F (C4 80 - C5 BF) [http://www.unicode.org/charts/PDF/U0180.pdf Latin Extended-B] U+0180–U+024F (C6 80 - C9 8F) [http://www.unicode.org/charts/PDF/U1E00.pdf Latin Extended Additional] U+1E00-U+1EFF (E1 B8 80 - E1 BB BF) [http://www.unicode.org/charts/PDF/U2C60.pdf Latin Extended-C] U+2C60–U+2C7F (E2 B1 A0 - E2 B1 BF) [http://www.unicode.org/charts/PDF/UA720.pdf Latin Extended-D] U+A720-U+A7FF (EA 9C A0 - EA 9F BF) [http://www.unicode.org/charts/PDF/UAB30.pdf Latin Extended-E] U+AB30-U+AB6F (EA AC B0 - EA AD AF) [http://www.unicode.org/charts/PDF/UFB00.pdf Alphabetic Presentaion Forms] U+FB00-U+FB06 (EF AC 80 - EF AC 86) [http://www.unicode.org/charts/PDF/UFF00.pdf Halfwidth and Fullwidth Forms] U+FF01-U+FF3C (EF BC 81 EF BC BC) does not include: [http://www.unicode.org/charts/PDF/U1D00.pdf Phonetic Extensions] U+1D00-U+1D7F (E1 B4 80 - E1 B5 BF) [http://www.unicode.org/charts/PDF/U0250.pdf IPA Extensions] U+0250-U+02AF (C9 90 - CA AF) [http://www.unicode.org/charts/PDF/U1D80.pdf Phonetic Extensions Supplement] U+1D80-U+1DBF (E1 B6 80 - E1 B6 BF) {{lang}} is used inside <poem>...</poem> tags for song lyrics, poetry, etc. <poem>...</poem> replaces newlines with poem stripmarkers. These have the form: ?'"`UNIQ--poem-67--QINU`"'? where the '?' character is actually the delete character (U+007F, \127). Including the '\n' (U+0010) and 'del' (U+007F) characters in the latn character table allows {{lang}} to auto-italicize text within <poem>...</poem> tags. ]] function p.is_latn (text) local latn = table.concat ( { '[', -- this is a set so include opening bracket '\n\32-\127', -- C0 Controls and Basic Latin U+0020–U+007E (20 - 7E) + (U+0010 and U+007F <poem>...</poem> support) '\194\160-\194\172', -- C1 Controls and Latin-1 Supplement U+00A0-U+00AC (C2 A0 - C2 AC) '\195\128-\195\191', -- (skip shy) U+00C0–U+00FF (C3 80 - C3 BF) '\196\128-\197\191', -- Latin Extended-A U+0100–U+017F (C4 80 - C5 BF) '\198\128-\201\143', -- Latin Extended-B U+0180–U+024F (C6 80 - C9 8F) '\225\184\128-\225\187\191', -- Latin Extended Additional U+1E00-U+1EFF (E1 B8 80 - E1 BB BF) '\226\177\160-\226\177\191', -- Latin Extended-C U+2C60–U+2C7F (E2 B1 A0 - E2 B1 BF) '\234\156\160-\234\159\191', -- Latin Extended-D U+A720-U+A7FF (EA 9C A0 - EA 9F BF) '\234\172\176-\234\173\175', -- Latin Extended-E U+AB30-U+AB6F (EA AC B0 - EA AD AF) '\239\172\128-\239\172\134', -- Alphabetic Presentaion Forms U+FB00-U+FB06 (EF AC 80 - EF AC 86) '\239\188\129-\239\188\188', -- Halfwidth and Fullwidth Forms U+FF01-U+FF3C (EF BC 81 - EF BC BC) '–', -- ndash '—', -- mdash '«', '»', -- guillemets commonly used in several 'Latn' languages ']', -- close the set }); text = mw.text.decode (text, true); -- replace numeric and named html entities with their unicode characters text = mw.ustring.gsub (text, '%[%[[^|]+|([^%]]+)%]%]', '%1'); -- remove the link and markup from complex wikilink in case interwiki to non-Latn wikipedia return not is_set (mw.ustring.gsub (text, latn, '')); -- replace all latn characters with empty space; if result is all empty space, text is latn end --[[--------------------------< I N V E R T _ I T A L I C S >------------------------------------------------- This function attempts to invert the italic markup a args.text by adding/removing leading/trailing italic markup in args.text. Like |italic=unset, |italic=invert disables automatic italic markup. Individual leading/trailing apostrophes are converted to their html numeric entity equivalent so that the new italic markup doesn't become bold markup inadvertently. Leading and trailing wiki markup is extracted from args.text into separate table elements. Addition, removal, replacement of wiki markup is handled by a string.gsub() replacement table operating only on these separate elements. In the string.gsub() matching pattern, '.*' matches empty string as well as the three expected wiki markup patterns. This function expects that markup in args.text is complete and correct; if it is not, oddness may result. ]] local function invert_italics (source) local invert_pattern_table = { -- leading/trailing markup add/remove/replace patterns [""]="\'\'", -- empty string becomes italic markup ["\'\'"]="", -- italic markup becomes empty string ["\'\'\'"]="\'\'\'\'\'", -- bold becomes bold italic ["\'\'\'\'\'"]="\'\'\'", -- bold italic become bold }; local seg = {}; source = source:gsub ("%f[\']\'%f[^\']", '&#38;'); -- protect single quote marks from being interpreted as bold markup seg[1] = source:match ('^(\'\'+%f[^\']).+') or ''; -- get leading markup, if any; ignore single quote seg[3] = source:match ('.+(%f[\']\'\'+)$') or ''; -- get trailing markup, if any; ignore single quote if '' ~= seg[1] and '' ~= seg[3] then -- extract the 'text' seg[2] = source:match ('^\'\'+%f[^\'](.+)%f[\']\'\'+$') -- from between leading and trailing markup elseif '' ~= seg[1] then seg[2] = source:match ('^\'\'+%f[^\'](.+)') -- following leading markup elseif '' ~= seg[3] then seg[2] = source:match ('(.+)%f[\']\'\'+$') -- preceding trailing markup else seg[2] = source -- when there is no markup end seg[1] = seg[1]:gsub (".*", invert_pattern_table, 1); -- replace leading markup according to pattern table seg[3] = seg[3]:gsub (".*", invert_pattern_table, 1); -- replace leading markup according to pattern table return table.concat (seg); -- put it all back together and done end --[[--------------------------< V A L I D A T E _ I T A L I C >------------------------------------------------ validates |italic= or |italics= assigned values. When |italic= is set and has an acceptible assigned value, return the matching css font-style property value or, for the special case 'default', return nil. When |italic= is not set, or has an unacceptible assigned value, return nil and a nil error message. When both |italic= and |italics= are set, returns nil and a 'conflicting' error message. The return value nil causes the calling lang, lang_xx, or transl function to set args.italic according to the template's defined default ('inherit' for {{lang}}, 'inherit' or 'italic' for {{lang-xx}} depending on the individual template's requirements, 'italic' for {{transl}}) or to the value appropriate to |script=, if set ({{lang}} and {{lang-xx}} only). Accepted values and the values that this function returns are are: nil - when |italic= absent or not set; returns nil default - for completeness, should rarely if ever be used; returns nil yes - force args.text to be rendered in italic font; returns 'italic' no - force args.text to be rendered in normal font; returns 'normal' unset - disables font control so that font-style applied to text is dictated by markup inside or outside the template; returns 'inherit' invert - disables font control so that font-style applied to text is dictated by markup outside or inverted inside the template; returns 'invert' ]] local function validate_italic (italic, italics) local properties = {['yes'] = 'italic', ['no'] = 'normal', ['unset'] = 'inherit', ['invert'] = 'invert', ['default'] = nil}; if italic and italics then -- return nil and an error message if both are set return nil, 'mâu thuẫn: &#124;italic= và &#124;italics='; end return properties[italic or italics], nil; -- return an appropriate value and a nil error message end --[[--------------------------< I N _ A R R A Y >-------------------------------------------------------------- Whether needle is in haystack ]] local function in_array( needle, haystack ) if needle == nil then return false; end for n,v in ipairs( haystack ) do if v == needle then return n; end end return false; end --[[--------------------------< F O R M A T _ I E T F _ T A G >------------------------------------------------ prettify ietf tags to use recommended subtag formats: code: lower case script: sentence case region: upper case variant: lower case ]] local function format_ietf_tag (code, script, region, variant) local out = {}; table.insert (out, code:lower()); if is_set (script) then script = script:lower():gsub ('^%a', string.upper); table.insert (out, script); end if is_set (region) then table.insert (out, region:upper()); end if is_set (variant) then table.insert (out, variant:lower()); end return table.concat (out, '-'); end --[[--------------------------< G E T _ I E T F _ P A R T S >-------------------------------------------------- extracts and returns IETF language tag parts: primary language subtag (required) - 2 or 3 character IANA language code script subtag - four character IANA script code region subtag - two-letter or three digit IANA region code variant subtag - four digit or 5-8 alnum variant code private subtag - x- followed by 1-8 alnum private code; only supported with the primary language tag in any one of these forms lang lang-variant lang-script lang-script-variant lang-region lang-region-variant lang-script-region lang-script-region-variant lang-x-private each of lang, script, region, variant, and private, when used, must be valid Languages with both two- and three-character code synonyms are promoted to the two-character synonym because the IANA registry file omits the synonymous three-character code; we cannot depend on browsers understanding the synonymous three-character codes in the lang= attribute. For {{lang-xx}} templates, the parameters |script=, |region=, and |variant= are supported (not supported in {{lang}} because those parameters are superfluous to the IETF subtags in |code=) returns six values. Valid parts are returned as themselves; omitted parts are returned as empty strings, invalid parts are returned as nil; the sixth returned item is an error message (if an error detected) or nil. see http://www.rfc-editor.org/rfc/bcp/bcp47.txt section 2.1 ]] local function get_ietf_parts (source, args_script, args_region, args_variant) local code; local script = ''; local region = ''; local variant = ''; local private = ''; if not is_set (source) then return nil, nil, nil, nil, nil, 'thiếu thẻ ngôn ngữ'; end if source:match ('^%a%a%a?%-%a%a%a%a%-%a%a%-%d%d%d%d$') then -- ll-Ssss-RR-variant (where variant is 4 digits) code, script, region, variant = source:match ('^(%a%a%a?)%-(%a%a%a%a)%-(%a%a)%-(%d%d%d%d)$'); elseif source:match ('^%a%a%a?%-%a%a%a%a%-%d%d%d%-%d%d%d%d$') then -- ll-Ssss-DDD-variant (where region is 3 digits; variant is 4 digits) code, script, region, variant = source:match ('^(%a%a%a?)%-(%a%a%a%a)%-(%d%d%d)%-(%d%d%d%d)$'); elseif source:match ('^%a%a%a?%-%a%a%a%a%-%a%a%-[%a%d][%a%d][%a%d][%a%d][%a%d]+$') then -- ll-Ssss-RR-variant (where variant is 5-8 alnum characters) code, script, region, variant = source:match ('^(%a%a%a?)%-(%a%a%a%a)%-(%a%a)%-([%a%d][%a%d][%a%d][%a%d][%a%d][%a%d]?[%a%d]?[%a%d]?)$'); elseif source:match ('^%a%a%a?%-%a%a%a%a%-%d%d%d%-[%a%d][%a%d][%a%d][%a%d][%a%d]+$') then -- ll-Ssss-DDD-variant (where region is 3 digits; variant is 5-8 alnum characters) code, script, region, variant = source:match ('^(%a%a%a?)%-(%a%a%a%a)%-(%d%d%d)%-([%a%d][%a%d][%a%d][%a%d][%a%d][%a%d]?[%a%d]?[%a%d]?)$'); elseif source:match ('^%a%a%a?%-%a%a%a%a%-%d%d%d%d$') then -- ll-Ssss-variant (where variant is 4 digits) code, script, variant = source:match ('^(%a%a%a?)%-(%a%a%a%a)%-(%d%d%d%d)$'); elseif source:match ('^%a%a%a?%-%a%a%a%a%-[%a%d][%a%d][%a%d][%a%d][%a%d]+$') then -- ll-Ssss-variant (where variant is 5-8 alnum characters) code, script, variant = source:match ('^(%a%a%a?)%-(%a%a%a%a)%-([%a%d][%a%d][%a%d][%a%d][%a%d][%a%d]?[%a%d]?[%a%d]?)$'); elseif source:match ('^%a%a%a?%-%a%a%-%d%d%d%d$') then -- ll-RR-variant (where variant is 4 digits) code, region, variant = source:match ('^(%a%a%a?)%-(%a%a)%-(%d%d%d%d)$'); elseif source:match ('^%a%a%a?%-%d%d%d%-%d%d%d%d$') then -- ll-DDD-variant (where region is 3 digits; variant is 4 digits) code, region, variant = source:match ('^(%a%a%a?)%-(%d%d%d)%-(%d%d%d%d)$'); elseif source:match ('^%a%a%a?%-%a%a%-[%a%d][%a%d][%a%d][%a%d][%a%d]+$') then -- ll-RR-variant (where variant is 5-8 alnum characters) code, region, variant = source:match ('^(%a%a%a?)%-(%a%a)%-([%a%d][%a%d][%a%d][%a%d][%a%d][%a%d]?[%a%d]?[%a%d]?)$'); elseif source:match ('^%a%a%a?%-%d%d%d%-[%a%d][%a%d][%a%d][%a%d][%a%d]+$') then -- ll-DDD-variant (where region is 3 digits; variant is 5-8 alnum characters) code, region, variant = source:match ('^(%a%a%a?)%-(%d%d%d)%-([%a%d][%a%d][%a%d][%a%d][%a%d][%a%d]?[%a%d]?[%a%d]?)$'); elseif source:match ('^%a%a%a?%-%d%d%d%d$') then -- ll-variant (where variant is 4 digits) code, variant = source:match ('^(%a%a%a?)%-(%d%d%d%d)$'); elseif source:match ('^%a%a%a?%-[%a%d][%a%d][%a%d][%a%d][%a%d][%a%d]?[%a%d]?[%a%d]?$') then -- ll-variant (where variant is 5-8 alnum characters) code, variant = source:match ('^(%a%a%a?)%-([%a%d][%a%d][%a%d][%a%d][%a%d][%a%d]?[%a%d]?[%a%d]?)$'); elseif source:match ('^%a%a%a?%-%a%a%a%a%-%a%a$') then -- ll-Ssss-RR code, script, region = source:match ('^(%a%a%a?)%-(%a%a%a%a)%-(%a%a)$'); elseif source:match ('^%a%a%a?%-%a%a%a%a%-%d%d%d$') then -- ll-Ssss-DDD (region is 3 digits) code, script, region = source:match ('^(%a%a%a?)%-(%a%a%a%a)%-(%d%d%d)$'); elseif source:match ('^%a%a%a?%-%a%a%a%a$') then -- ll-Ssss code, script = source:match ('^(%a%a%a?)%-(%a%a%a%a)$'); elseif source:match ('^%a%a%a?%-%a%a$') then -- ll-RR code, region = source:match ('^(%a%a%a?)%-(%a%a)$'); elseif source:match ('^%a%a%a?%-%d%d%d$') then -- ll-DDD (region is 3 digits) code, region = source:match ('^(%a%a%a?)%-(%d%d%d)$'); elseif source:match ('^%a%a%a?$') then -- ll code = source:match ('^(%a%a%a?)$'); elseif source:match ('^%a%a%a?%-x%-[%a%d][%a%d]?[%a%d]?[%a%d]?[%a%d]?[%a%d]?[%a%d]?[%a%d]?$') then -- ll-x-pppppppp) code, private = source:match ('^(%a%a%a?)%-x%-([%a%d]+)$'); else return nil, nil, nil, nil, nil, table.concat ({'thẻ ngôn ngữ không rõ: ', source}); -- don't know what we got but it is malformed end code = code:lower(); -- ensure that we use and return lower case version of this if not (lang_data.override[code] or lang_name_table.lang[code]) then return nil, nil, nil, nil, nil, table.concat ({'mã ngôn ngữ không rõ: ', code}); -- invalid language code, don't know about the others (don't care?) end if synonym_table[code] then -- if 639-2/639-2T code has a 639-1 synonym table.insert (maint_cats, table.concat ({'Mã lang và lang-xx được nâng cấp thành ISO 639-1|', code})); table.insert (maint_msgs, table.concat ({'mã ngôn ngữ: ', code, ' được nâng cấp thành mã: ', synonym_table[code]})); code = synonym_table[code]; -- use the synonym end if is_set (script) then if is_set (args_script) then return code, nil, nil, nil, nil, 'thẻ hệ chữ viết thừa'; -- both code with script and |script= not allowed end else script = args_script or ''; -- use args.script if provided end if is_set (script) then script = script:lower(); -- ensure that we use and return lower case version of this if not lang_name_table.script[script] then return code, nil, nil, nil, nil, table.concat ({'hệ chữ viết không rõ: ', script, ' cho mã ngôn ngữ: ', code}); -- language code ok, invalid script, don't know about the others (don't care?) end end if lang_name_table.suppressed[script] then -- ensure that code-script does not use a suppressed script if in_array (code, lang_name_table.suppressed[script]) then return code, nil, nil, nil, nil, table.concat ({'không hỗ trợ hệ chữ viết: ', script, ' cho mã ngôn ngữ: ', code}); -- language code ok, script is suppressed for this code end end if is_set (region) then if is_set (args_region) then return code, nil, nil, nil, nil, 'thẻ vùng thừa'; -- both code with region and |region= not allowed end else region = args_region or ''; -- use args.region if provided end if is_set (region) then region = region:lower(); -- ensure that we use and return lower case version of this if not lang_name_table.region[region] then return code, script, nil, nil, nil, table.concat ({'vùng không rõ: ', region, ' cho mã ngôn ngữ: ', code}); end end if is_set (variant) then if is_set (args_variant) then return code, nil, nil, nil, nil, 'thẻ biến thể thừa'; -- both code with variant and |variant= not allowed end else variant = args_variant or ''; -- use args.variant if provided end if is_set (variant) then variant = variant:lower(); -- ensure that we use and return lower case version of this if not lang_name_table.variant[variant] then -- make sure variant is valid return code, script, region, nil, nil, table.concat ({'biến thể không rõ: ', variant}); end -- does this duplicate/replace tests in lang() and lang_xx()? if is_set (script) then -- if script set it must be part of the 'prefix' if not in_array (table.concat ({code, '-', script}), lang_name_table.variant[variant]['prefixes']) then return code, script, region, nil, nil, table.concat ({'biến thể không rõ: ', variant, ' for code-script pair: ', code, '-', script}); end else if not in_array (code, lang_name_table.variant[variant]['prefixes']) then return code, script, region, nil, nil, table.concat ({'biến thể không rõ: ', variant, ' cho mã ngôn ngữ: ', code}); end end end if is_set (private) then private = private:lower(); -- ensure that we use and return lower case version of this if not lang_data.override[table.concat ({code, '-x-', private})] then -- make sure private tag is valid; note that index return code, script, region, nil, nil, table.concat ({'thẻ riêng tư không rõ: ', private}); end end return code, script, region, variant, private, nil; -- return the good bits; make sure that msg is nil end --[[--------------------------< M A K E _ E R R O R _ M S G >-------------------------------------------------- assembles an error message from template name, message text, help link, and error category. ]] local function make_error_msg (msg, args, template) local out = {}; local category; if 'transl' == template then category = 'transl'; else category = 'lang và lang-xx' end table.insert (out, table.concat ({'&#x5B;', args.text or 'undefined', '&#x5D; '})); -- for error messages output args.text if available table.insert (out, table.concat ({'<span style=\"font-size:100%; font-style:normal;\" class=\"error\">lỗi: {{', template, '}}: '})); table.insert (out, msg); table.insert (out, table.concat ({' ([[:Thể loại:Lỗi bản mẫu ', category, '|trợ giúp]])'})); table.insert (out, '</span>'); if (0 == namespace) and not is_set (args.nocat) then -- only categorize in article space table.insert (out, table.concat ({'[[Thể loại:Lỗi bản mẫu ', category, ']]'})); end return table.concat (out); end --[=[-------------------------< M A K E _ W I K I L I N K >---------------------------------------------------- Makes a wikilink; when both link and display text is provided, returns a wikilink in the form [[L|D]]; if only link is provided, returns a wikilink in the form [[L]]; if neither are provided or link is omitted, returns an empty string. ]=] local function make_wikilink (link, display) if is_set (link) then if is_set (display) then return table.concat ({'[[', link, '|', display, ']]'}); else return table.concat ({'[[', link, ']]'}); end else return ''; end end --[[--------------------------< M A K E _ T E X T _ S P A N >-------------------------------------------------- TODO: add support for block: div tags instead of span tags; would need some sort of proper parameter to control the switch For italic style, can't do ''{{lang|xx|text}}'' without using <span/> tags when text is italic because of -Latn, |italic=yes, or auto-italics because the wrapping wikimarkup produces this: <i><i lang="xx">text</i></i> which is later reduced to this: <i>text</i> This reduction happens in some sort of cleanup process outside the scope of this template/module. Until or unless this is fixed italic text must be: <i><span lang="xx">text</span></i> ]] local function make_text_span (code, text, rtl, style, size, language) local span = {}; local style_added = ''; if text:match ('^%*') then table.insert (span, '&#42;'); -- move proto language text prefix outside of italic markup if any; use numeric entity because plan splat confuses MediaWiki text = text:gsub ('^%*', ''); -- remove the splat from the text end if 'italic' == style then table.insert (span, '<i>'); -- open italic style tag end table.insert (span, table.concat ({'<span lang="'})); -- open <span> tag table.insert (span, table.concat ({code, '\"'})); -- add language attribute if rtl then table.insert (span, ' dir="rtl"'); -- add direction attribute for right to left languages end if 'normal' == style then -- when |italic=no table.insert (span, ' style=\"font-style:normal;'); -- override external markup, if any style_added = '\"'; -- remember that style attribute added and is not yet closed end if is_set (size) then -- when |size=<something> if is_set (style_added) then table.insert (span, table.concat ({' font-size:', size, ';'})); -- add when style attribute already inserted else table.insert (span, table.concat ({' style=\"font-size:', size, ';'})); -- create style attribute style_added = '\"'; -- remember that style attribute added and is not yet closed end end if is_set (language) then table.insert (span, table.concat ({style_added, ' title=\"'})); --start the title text if language:find ('languages') then table.insert (span, 'Văn bản ngôn ngữ '); -- for collective languages else table.insert (span, 'Văn bản tiếng '); -- for individual languages end table.insert (span, table.concat ({language, '\">'})); -- close the opening span tag else table.insert (span, table.concat ({style_added, '>'})); -- close the style attribute and close opening span tag end table.insert (span, text); -- insert the text table.insert (span, '</span>'); -- close the <span> tag if 'italic' == style then table.insert (span, '</i>'); -- close italic style tag end if rtl then -- legacy; shouldn't be necessary because all of the rtl text is wrapped in <span dir="rtl">text</span> table.insert (span, '&lrm;'); -- make sure the browser knows that we're at the end of the rtl end return table.concat (span); -- put it all together and done end --[=[-------------------------< M A K E _ C A T E G O R Y >---------------------------------------------------- For individual language, <language>, returns: [[Thể loại:Bài viết có văn bản <language>]] for Vietnamese: [[Thể loại:Bài viết có văn bản tiếng Việt nêu rõ]] for artificial languages (code: art) [[Thể loại:Bài viết có văn bản trong ngôn ngữ được xây dựng]] for ISO 639-2 collective languages (and for 639-1 bh): [[Thể loại:Bài viết có văn bản <language>]] ]=] local function make_category (code, language_name, nocat) local cat = {}; if (0 ~= namespace) or nocat then -- only categorize in article space return ''; -- return empty string for concatenation end if isCollective(language_name) then return table.concat ({'[[Thể loại:Bài viết có văn bản ', language_name, ']]'}); end table.insert (cat, '[[Thể loại:Bài viết có văn bản '); if 'vi' == code then table.insert (cat, 'tiếng Việt nêu rõ'); elseif 'art' == code then table.insert (cat, 'trong ngôn ngữ được xây dựng') else table.insert (cat, 'tiếng ' .. language_name); end table.insert (cat, ']]'); return table.concat (cat); end --[[--------------------------< M A K E _ T R A N S L I T >---------------------------------------------------- return translit <i lang=xx-Latn>...</i> where xx is the language code; else return empty string The value |script= is not used in {{transl}} for this purpose; instead it uses |code. Because language scripts are listed in the {{transl}} switches they are included in the data tables. The script parameter is introduced at {{Language with name and transliteration}}. If |script= is set, this function uses it in preference to code. To avoid confusion, in this module and the templates that use it, the transliteration script parameter is renamed to be |translit-script= (in this function, tscript) This function is used by both lang_xx() and transl() lang_xx() always provides code, language_name, and translit; may provide tscript; never provides style transl() always provides language_name, translit, and one of code or tscript, never both; always provides style For {{transl}}, style only applies when a language code is provided ]] local function make_translit (code, language_name, translit, std, tscript, style) local title; local tout = {}; local title_table = lang_data.translit_title_table; -- table of transliteration standards and the language codes and scripts that apply to those standards if is_set (code) then -- when a language code is provided (always with {{lang-xx}} templates, not always with {{transl}}) if not style then -- nil for is the default italic style table.insert (tout, "<i lang=\""); -- so use <i> tag else table.insert (tout, table.concat ({'<span style=\"font-style:', style, '\" lang=\"'})); -- non-standard style, construct a span tag for it end table.insert (tout, code); table.insert (tout, "-Latn\" title=\""); -- transliterations are always Latin script else table.insert (tout, "<span title=\""); -- when no language code: no lang= attribute, not italic ({{transl}} only) end std = std and std:lower(); -- lower case for table indexing if not is_set (std) and not is_set (tscript) then -- when neither standard nor script specified table.insert (tout, 'Chuyển tự '); -- start the tool tip if not isCollective(language_name) then -- collective language names (plural 'languages' is part of the name) table.insert (tout, 'tiếng ') -- skip this text (individual and macro languages only) end table.insert (tout, language_name); -- write a generic tool tip elseif is_set (std) and is_set (tscript) then -- when both are specified if title_table[std] then -- and if standard is legitimate if title_table[std][tscript] then -- and if script for that standard is legitimate table.insert (tout, table.concat ({'Chuyển tự tiếng ', title_table[std][tscript:lower()], ' (chữ ', lang_name_table.script[tscript][1]})); -- add the appropriate text to the tool tip else table.insert (tout, title_table[std]['default']); -- use the default if script not in std table; TODO: maint cat? error message because script not found for this standard? end else return ''; -- invalid standard, setup for error message end elseif is_set (std) then -- translit-script not set, use language code if not title_table[std] then return ''; end -- invalid standard, setup for error message if title_table[std][code] then -- if language code is in the table (transl may not provide a language code) table.insert (tout, table.concat ({title_table[std][code:lower()], ' (', lang_name_table.lang[code][1], ' language) transliteration'})); -- add the appropriate text to the tool tip else -- code doesn't match table.insert (tout, title_table[std]['default']); -- so use the standard's default end else -- here if translit-script set but translit-std not set if title_table['no_std'][tscript] then table.insert (tout, title_table['no_std'][tscript]); -- use translit-script if set elseif title_table['no_std'][code] then table.insert (tout, title_table['no_std'][code]); -- use language code else if is_set (tscript) then table.insert (tout, table.concat ({'Chuyển tự tiếng ', language_name})); -- write a script tool tip elseif is_set (code) then if not isCollective(language_name) then -- collective language names (plural 'languages' is part of the name) table.insert (tout, '-language') -- skip this text (individual and macro languages only) end table.insert (tout, ' transliteration'); -- finish the tool tip else table.insert (tout, ' transliteration'); -- generic tool tip (can we ever get here?) end end end table.insert (tout, '">'); table.insert (tout, translit); if is_set (code) and not style then -- when a language code is provided (always with {{lang-xx}} templates, not always with {{transl}}) table.insert (tout, "</i>"); -- close the italic tag else table.insert (tout, "</span>"); -- no language code so close the span tag end return table.concat (tout); end --[=[-------------------------< V A L I D A T E _ T E X T >--------------------------------------------------- This function checks the content of args.text and returns empty string if nothing is amiss else it returns an error message. The tests are for empty or missing text and for improper or disallowed use of apostrophe markup. Italic rendering is controlled by the |italic= template parameter so italic markup should never appear in args.text either as ''itself''' or as '''''bold italic'''''. ]=] local function validate_text (template, args) if not is_set (args.text) then return make_error_msg ('không có văn bản', args, template); end if args.text:find ("%f[\']\'\'\'\'%f[^\']") or args.text:find ("\'\'\'\'\'[\']+") then -- because we're looking, look for 4 appostrophes or 6+ appostrophes return make_error_msg ('văn bản có thẻ đánh dấu hỏng', args, template); end local style = args.italic or args.italics; -- if ('unset' ~= args.italic) and ('unset' ~= args.italics) then -- allow italic markup when |italic=unset or |italics=unset if ('unset' ~= style) and ('invert' ~=style) then if args.text:find ("%f[\']\'\'%f[^\']") or args.text:find ("%f[\']\'\'\'\'\'%f[^\']") then -- italic but not bold, or bold italic return make_error_msg ('văn bản có thẻ đánh dấu in xiên', args, template); end end end --[[--------------------------< R E N D E R _ M A I N T >------------------------------------------------------ render mainenance messages and categories ]] local function render_maint(nocat) local maint = {}; if 0 < #maint_msgs then -- when there are maintenance messages table.insert (maint, table.concat ({'<span class="lang-comment" style="font-style:normal; display:none; color:#33aa33; margin-left:0.3em">'})); -- opening <span> tag for _, msg in ipairs (maint_msgs) do table.insert (maint, table.concat ({msg, ' '})); -- add message strings end table.insert (maint, '</span>'); -- close the span end if (0 < #maint_cats) and (0 == namespace) and not is_set (nocat) then -- when there are mainenance categories; article namespace only for _, cat in ipairs (maint_cats) do table.insert (maint, table.concat ({'[[Thể loại:', cat, ']]'})); -- format and add the categories end end return table.concat (maint); end --[[--------------------------< P R O T O _ P R E F I X >------------------------------------------------------ for proto languages, text is prefixed with a splat. We do that here as a flag for make_text_span() so that a splat will be rendered outside of italic markup (if used). If the first character in text here is already a splat, we do nothing ]] local function proto_prefix (text, language_name) if (language_name:find ('^Proto%-') or language_name:find (' nguyên th[uủ][yỷ]$')) and not text:find ('^*') then -- language is a proto and text does not already have leading splat return table.concat ({'*', text}); -- prefix proto language text with a splat end return text; end --[[--------------------------< L A N G >---------------------------------------------------------------------- entry point for {{lang}} there should be no reason to set parameters in the {{lang}} {{#invoke:}} <includeonly>{{#invoke:lang|lang}}</includeonly> parameters are recieved from the template's frame (parent frame) ]] function p.lang (frame) local args = getArgs(frame); local out = {}; local language_name; -- used to make category names local subtags = {}; -- IETF subtags script, region, variant, and private local code; -- the language code local msg; -- for error messages if args[1] and args.code then return make_error_msg ('mâu thuẫn: {{{1}}} và &#124;code=', args, 'lang'); else args.code = args[1] or args.code; -- prefer args.code end if args[2] and args.text then return make_error_msg ('mâu thuẫn: {{{2}}} và &#124;text=', args, 'lang'); else args.text = args[2] or args.text; -- prefer args.text end msg = validate_text ('lang', args); -- ensure that |text= is set (italic test disabled for the time being) if is_set (msg) then -- msg is an already-formatted error message return msg; end args.rtl = args.rtl == 'yes'; -- convert to boolean: 'yes' -> true, other values -> false code, subtags.script, subtags.region, subtags.variant, subtags.private, msg = get_ietf_parts (args.code); -- |script=, |region=, |variant= not supported because they should be part of args.code ({{{1}}} in {{lang}}) if msg then return make_error_msg ( msg, args, 'lang'); end args.italic, msg = validate_italic (args.italic, args.italics); if msg then return make_error_msg (msg, args, 'lang'); end if nil == args.italic then -- nil when |italic= absent or not set or |italic=default; args.italic controls if ('latn' == subtags.script) or (p.is_latn (args.text) and 'vi' ~= code) then -- script set to latn or text is wholly latn script but not rendering Vietnamese args.italic = 'italic'; -- DEFAULT for {{lang}} templates is upright; but if latn script set for font-style:italic else args.italic = 'inherit'; -- italic not set; script not latn; inherit current style end end if is_set (subtags.script) then -- if script set, override rtl setting if in_array (subtags.script, lang_data.rtl_scripts) then args.rtl = true; -- script is an rtl script else args.rtl = false; -- script is not an rtl script end end args.code = format_ietf_tag (code, subtags.script, subtags.region, subtags.variant); -- format to recommended subtag styles; private omitted because private if is_set (subtags.private) and lang_data.override[table.concat ({code, '-x-', subtags.private})] then -- look for private use tags; done this way because ... language_name = lang_data.override[table.concat ({code, '-x-', subtags.private})][1]; -- ... args.code does not get private subtag elseif lang_data.override[code] then -- get the language name for categorization language_name = lang_data.override[code][1] -- prefer language names taken from the override table elseif lang_name_table.lang[code] then language_name = lang_name_table.lang[code][1]; -- table entries sometimes have multiple names, always take the first one end if 'invert' == args.italic then args.text = invert_italics (args.text) end args.text = proto_prefix (args.text, language_name); -- prefix proto-language text with a splat table.insert (out, make_text_span (args.code, args.text, args.rtl, args.italic, args.size, language_name)); table.insert (out, make_category (code, language_name, args.nocat)); table.insert (out, render_maint(args.nocat)); -- maintenance messages and categories return table.concat (out); -- put it all together and done end --[[--------------------------< L A N G _ X X >---------------------------------------------------------------- For the {{lang-xx}} templates, the only parameter required to be set in the template is the language code. All other parameters can, usually should, be written in the template call. For {{lang-xx}} templates for languages that can have multiple writing systems, it may be appropriate to set |script= as well. For each {{lang-xx}} template choose the appropriate entry-point function so that this function know the default styling that should be applied to text. For normal, upright style: <includeonly>{{#invoke:lang|lang_xx_inherit|code=xx}}</includeonly> For italic style: <includeonly>{{#invoke:lang|lang_xx_italic|code=xx}}</includeonly> All other parameters should be received from the template's frame (parent frame) Supported parameters are: |code = (required) the IANA language code |script = IANA script code; especially for use with languages that use multiple writing systems; yields to the script subtag in |code= if present [not yet implemented] |region = IANA region code |variant = IANA variant code |text = (required) the displayed text in language specified by code |link = boolean false ('no') unlinks language specified by code to associated language article |rtl = boolean true ('yes') identifies the language specified by code as a right-to-left language |nocat = boolean true ('yes') inhibits normal categorization; error categories are not affected |italic = boolean true ('yes') renders displayed text in italic font; boolean false ('no') renders displayed text in normal font; not set renders according to initial_style_state |lit = text that is a literal translation of text |label = 'none' to suppress all labeling (language name, 'translit.', 'lit.') any other text replaces language-name label - automatic wikilinking disabled for those {{lang-xx}} templates that support transliteration (those template where |text= is entirely latn script): |translit = text that is a transliteration of text |translit-std = the standard that applies to the transliteration |translit-script = ISO 15924 script name; falls back to code For {{lang-xx}}, the positional parameters are: {{{1}}} text {{{2}}} transliterated text {{{3}}} literal translation text no other positional parameters are allowed ]] local function _lang_xx (frame) local args = getArgs(frame, {parentFirst= true}); -- parameters in the template override parameters set in the {{#invoke:}} local out = {}; local language_name; -- used to make display text, article links local category_name; -- same as language_name except that it retains any parenthetical disambiguators (if any) from the data set local subtags = {}; -- IETF subtags script, region, and variant local code; -- the language code local translit_script_name; -- name associated with IANA (ISO 15924) script code local translit; local translit_title; local msg; -- for error messages if args[1] and args.text then return make_error_msg ('mâu thuẫn: {{{1}}} và &#124;text=', args, 'lang-xx'); else args.text = args[1] or args.text; -- prefer args.text end msg = validate_text ('lang-xx', args); -- ensure that |text= is set, does not contain italic markup and is protected from improper bolding if is_set (msg) then return msg; end if args[2] and args.translit then return make_error_msg ('mâu thuẫn: {{{2}}} và &#124;translit=', args, 'lang-xx'); else args.translit = args[2] or args.translit -- prefer args.translit end if args[3] and (args.translation or args.lit) then return make_error_msg ('mâu thuẫn: {{{3}}} và &#124;lit= hoặc &#124;translation=', args, 'lang-xx'); elseif args.translation and args.lit then return make_error_msg ('mâu thuẫn: &#124;lit= và &#124;translation=', args, 'lang-xx'); else args.translation = args[3] or args.translation or args.lit; -- prefer args.translation end if args.links and args.link then return make_error_msg ('mâu thuẫn: &#124;links= và &#124;link=', args, 'lang-xx'); else args.link = args.link or args.links; -- prefer args.link end args.rtl = args.rtl == 'yes'; -- convert to boolean: 'yes' -> true, other values -> false code, subtags.script, subtags.region, subtags.variant, subtags.private, msg = get_ietf_parts (args.code, args.script, args.region, args.variant); -- private omitted because private if msg then -- if an error detected then there is an error message return make_error_msg (msg, args, 'lang-xx'); end args.italic, msg = validate_italic (args.italic, args.italics); if msg then return make_error_msg (msg, args, 'lang-xx'); end if nil == args.italic then -- args.italic controls if is_set (subtags.script) then if 'latn' == subtags.script then args.italic = 'italic'; -- |script=Latn; set for font-style:italic else args.italic = initial_style_state; -- italic not set; script is not latn; set for font-style:<initial_style_state> end else args.italic = initial_style_state; -- here when |italic= and |script= not set; set for font-style:<initial_style_state> end end if is_set (subtags.script) then -- if script set override rtl setting if in_array (subtags.script, lang_data.rtl_scripts) then args.rtl = true; -- script is an rtl script else args.rtl = false; -- script is not an rtl script end end args.code = format_ietf_tag (code, subtags.script, subtags.region, subtags.variant); -- format to recommended subtag styles if is_set (subtags.private) and lang_data.override[table.concat ({code, '-x-', subtags.private})] then -- look for private use tags; done this way because ... language_name = lang_data.override[table.concat ({code, '-x-', subtags.private})][1]; -- ... args.code does not get private subtag elseif lang_data.override[args.code:lower()] then -- look for whole IETF tag in override table language_name = lang_data.override[args.code:lower()][1]; -- args.code:lower() because format_ietf_tag() returns mixed case elseif lang_data.override[code] then -- not there so try basic language code language_name = lang_data.override[code][1]; elseif not is_set (subtags.variant) then if lang_name_table.lang[code] then language_name = lang_name_table.lang[code][1]; -- table entries sometimes have multiple names, always take the first one end else -- TODO: is this the right thing to do: take language display name from variants table? if lang_name_table.variant[subtags.variant] then -- TODO: there is some discussion at Template talk:Lang about having a label parameter for use when variant name is not desired among other things language_name = lang_name_table.variant[subtags.variant]['descriptions'][1]; -- table entries sometimes have multiple names, always take the first one end end category_name = language_name; -- category names retain IANA parenthetical diambiguators (if any) language_name = language_name:gsub ('%s+%b()', ''); -- remove IANA parenthetical disambiguators or qualifiers from names that have them if args.label then if 'none' ~= args.label then table.insert (out, table.concat ({'tiếng ', args.label, ': '})); -- custom label end else if 'no' == args.link then table.insert (out, table.concat ({'tiếng ', language_name})); -- language name without wikilink else if isCollective(language_name) then table.insert (out, make_wikilink (language_name)); -- collective language name uses simple wikilink else table.insert (out, make_wikilink (table.concat ({'tiếng ', language_name}))); -- language name with wikilink end end table.insert (out, ': '); -- separator end if 'invert' == args.italic then args.text = invert_italics (args.text) end args.text = proto_prefix (args.text, language_name); -- prefix proto-language text with a splat table.insert (out, make_text_span (args.code, args.text, args.rtl, args.italic, args.size)) if is_set (args.translit) and not p.is_latn (args.text) then -- transliteration (not supported in {{lang}}); not supported when args.text is wholly latn text (this is an imperfect test) table.insert (out, ', '); -- comma to separate text from translit if 'none' ~= args.label then table.insert (out, '<small>'); if lang_name_table.script[args['translit-script']] then -- when |translit-script= is set, try to use the script's name translit_script_name = lang_name_table.script[args['translit-script'][1]]; else translit_script_name = language_name; -- fall back on language name end translit_title = mw.title.makeTitle (0, table.concat ({'Latinh hóa chữ ', translit_script_name})); -- make a title object if translit_title.exists and ('no' ~= args.link) then table.insert (out, make_wikilink ('Latinh hóa chữ ' .. translit_script_name or language_name, 'chuyển&nbsp;tự')); -- make a wikilink if there is an article to link to else table.insert (out, 'chuyển&nbsp;tự'); -- else define the abbreviation end table.insert (out, '&nbsp;</small>'); -- close the small tag end translit = make_translit (args.code, language_name, args.translit, args['translit-std'], args['translit-script']) if is_set (translit) then table.insert (out, translit); else return make_error_msg (table.concat ({'translit-std không hợp lệ: \'', args['translit-std'] or '[missing]'}), args, 'lang-xx'); end end if is_set (args.translation) then -- translation (not supported in {{lang}}) table.insert (out, ', '); if 'none' ~= args.label then table.insert (out, '<small>'); if 'no' == args.link then table.insert (out, 'dịch nguyên&nbsp;văn'); else table.insert (out, make_wikilink ('Dịch nguyên văn', 'nguyên&nbsp;văn')); end table.insert (out, "&nbsp;</small>"); end table.insert (out, table.concat ({'&#39;', args.translation, '&#39;'})); -- use html entities to avoid wiki markup confusion end table.insert (out, make_category (code, category_name, args.nocat)); table.insert (out, render_maint(args.nocat)); -- maintenance messages and categories return table.concat (out); -- put it all together and done end --[[--------------------------< L A N G _ X X _ I T A L I C >-------------------------------------------------- Entry point for those {{lang-xx}} templates that call lang_xx_italic(). Sets the initial style state to italic. ]] function p.lang_xx_italic (frame) initial_style_state = 'italic'; return _lang_xx (frame); end --[[--------------------------< L A N G _ X X _ I N H E R I T >------------------------------------------------ Entry point for those {{lang-xx}} templates that call lang_xx_inherit(). Sets the initial style state to inherit. ]] function p.lang_xx_inherit (frame) initial_style_state = 'inherit'; return _lang_xx (frame); end --[[--------------------------< N A M E _ F R O M _ C O D E >-------------------------------------------------- Returns language name associated with IETF language tag if valid; empty string else. All code combinations supported by {{lang}} and the {{lang-xx}} templates are supported by this function. ]] function p.name_from_code (frame) local subtags = {}; -- IETF subtags script, region, variant, and private local raw_code = (frame.args and frame.args[1]) or frame; -- save a copy of the input local code; -- the language code local msg; -- holds an error message (not used here) if IETF language tag is malformed or invalid local language_name = ''; code, subtags.script, subtags.region, subtags.variant, subtags.private, msg = get_ietf_parts (raw_code); if msg then return ''; end if lang_data.override[raw_code:lower()] then -- look for whole IETF tag in override table (force lower case) language_name = lang_data.override[raw_code:lower()][1]; elseif lang_data.override[code] then -- not there so try basic language code in override table language_name = lang_data.override[code][1]; elseif not is_set (subtags.variant) then if lang_name_table.lang[code] then language_name = lang_name_table.lang[code][1]; -- table entries sometimes have multiple names, always take the first one end else -- TODO: is this the right thing to do: take language display name from variants table? if lang_name_table.variant[subtags.variant] then -- TODO: there is some discussion at Template talk:Lang about having a label parameter for use when variant name is not desired among other things language_name = lang_name_table.variant[subtags.variant]['descriptions'][1]; -- table entries sometimes have multiple names, always take the first one end end language_name = language_name:gsub ('%s+%b()', ''); -- remove IANA parenthetical disambiguators or qualifiers from names that have them return language_name; end --[[--------------------------< T R A N S L >------------------------------------------------------------------ Prospective replacement for the template {{transl}} ]] function p.transl (frame) local args = getArgs(frame); -- no {{#invoke:}} parameters local title_table = lang_data.translit_title_table; -- table of transliteration standards and the language codes and scripts that apply to those standards local language_name; -- language name that matches language code; used for tool tip local translit; -- translitterated text to display local script; -- IANA script local msg; -- for when called functions return an error message if is_set (args[3]) then -- [3] set when {{transl|code|standard|text}} args.text = args[3]; -- get the transliterated text args.translit_std = args[2] and args[2]:lower(); -- get the standard; lower case for table indexing if not title_table[args.translit_std] then return make_error_msg (table.concat ({'tiêu chuẩn chuyển tự không rõ: ', args.translit_std}), args, 'transl'); end else if is_set (args[2]) then -- [2] set when {{transl|code|text}} args.text = args[2]; -- get the transliterated text else if args[1] and args[1]:match ('^%a%a%a?%a?$') then -- args[2] missing; is args[1] a code or its it the transliterated text? return make_error_msg ('không có văn bản', args, 'transl'); -- args[1] is a code so we're missing text else args.text = args[1]; -- args[1] is not a code so we're missing that; assign args.text for error message return make_error_msg ('thiếu mã ngôn ngữ / hệ chữ viết', args, 'transl'); end end end if is_set (args[1]) then -- IANA language code used for html lang= attribute; or ISO 15924 script code if args[1]:match ('^%a%a%a?%a?$') then -- args[1] has correct form? args.code = args[1]:lower(); -- use the language/script code; only (2, 3, or 4 alpha characters); lower case because table indexes are lower case else return make_error_msg (table.concat ({'mã ngôn ngữ / hệ chữ viết không rõ: ', args[1]}), args, 'transl'); -- invalid language / script code end else return make_error_msg ('thiếu mã ngôn ngữ / hệ chữ viết', args, 'transl'); -- missing language / script code so quit end args.italic, msg = validate_italic (args.italic, args.italics); if msg then return make_error_msg (msg, args, 'transl'); end if 'italic' == args.italic then -- 'italic' when |italic=yes; because that is same as absent or not set and |italic=default args.italic = nil; -- set to nil; end if lang_data.override[args.code] then -- is code a language code defined in the override table? language_name = lang_data.override[args.code][1]; elseif lang_name_table.lang[args.code] then -- is code a language code defined in the standard language code tables? language_name = lang_name_table.lang[args.code][1]; elseif lang_name_table.script[args.code] then -- if here, code is not a language code; is it a script code? language_name = lang_name_table.script[args.code][1]; script = args.code; -- code was an ISO 15924 script so use that instead args.code = ''; -- unset because not a language code else return make_error_msg (table.concat ({'mã ngôn ngữ / hệ chữ viết không rõ: ', args.code}), args, 'transl'); -- invalid language / script code end -- here only when all parameters passed to make_translit() are valid return make_translit (args.code, language_name, args.text, args.translit_std, script, args.italic); end return p; </textarea><div id="mw-scribunto-console"></div><div class="templatesUsed"><div class="mw-templatesUsedExplanation"><p>Các bản mẫu dùng trong trang này: </p></div><ul> <li><a href="/wiki/B%E1%BA%A3n_m%E1%BA%ABu:T%C3%A0i_li%E1%BB%87u" title="Bản mẫu:Tài liệu">Bản mẫu:Tài liệu</a> (<a href="/w/index.php?title=B%E1%BA%A3n_m%E1%BA%ABu:T%C3%A0i_li%E1%BB%87u&action=edit" title="Bản mẫu:Tài liệu">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Arguments" title="Mô đun:Arguments">Mô đun:Arguments</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Arguments&action=edit" title="Mô đun:Arguments">xem mã nguồn</a>) (bị khóa)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Documentation" title="Mô đun:Documentation">Mô đun:Documentation</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Documentation&action=edit" title="Mô đun:Documentation">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Documentation/config" title="Mô đun:Documentation/config">Mô đun:Documentation/config</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Documentation/config&action=edit" title="Mô đun:Documentation/config">xem mã nguồn</a>) (hạn chế cho thành viên xác nhận mở rộng)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Documentation/styles.css" title="Mô đun:Documentation/styles.css">Mô đun:Documentation/styles.css</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Documentation/styles.css&action=edit" title="Mô đun:Documentation/styles.css">xem mã nguồn</a>) (hạn chế cho thành viên xác nhận mở rộng)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Effective_protection_expiry" title="Mô đun:Effective protection expiry">Mô đun:Effective protection expiry</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Effective_protection_expiry&action=edit" title="Mô đun:Effective protection expiry">xem mã nguồn</a>) (bị khóa hạn chế sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Effective_protection_level" title="Mô đun:Effective protection level">Mô đun:Effective protection level</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Effective_protection_level&action=edit" title="Mô đun:Effective protection level">xem mã nguồn</a>) (hạn chế cho thành viên xác nhận mở rộng)</li><li><a href="/wiki/M%C3%B4_%C4%91un:File_link" title="Mô đun:File link">Mô đun:File link</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:File_link&action=edit" title="Mô đun:File link">xem mã nguồn</a>) (bị khóa hạn chế sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Lang" title="Mô đun:Lang">Mô đun:Lang</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang&action=edit" title="Mô đun:Lang">xem mã nguồn</a>) (bị khóa)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Lang/ISO_639_synonyms" title="Mô đun:Lang/ISO 639 synonyms">Mô đun:Lang/ISO 639 synonyms</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang/ISO_639_synonyms&action=edit" title="Mô đun:Lang/ISO 639 synonyms">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Lang/data" title="Mô đun:Lang/data">Mô đun:Lang/data</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang/data&action=edit" title="Mô đun:Lang/data">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang/t%C3%A0i_li%E1%BB%87u&action=edit&redlink=1" class="new" title="Mô đun:Lang/tài liệu (trang không tồn tại)">Mô đun:Lang/tài liệu</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Lang/t%C3%A0i_li%E1%BB%87u&action=edit" class="new" title="Mô đun:Lang/tài liệu (trang không tồn tại)">sửa đổi</a>) </li><li><a href="/wiki/M%C3%B4_%C4%91un:Language/data/ISO_639-3" title="Mô đun:Language/data/ISO 639-3">Mô đun:Language/data/ISO 639-3</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Language/data/ISO_639-3&action=edit" title="Mô đun:Language/data/ISO 639-3">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Language/data/iana_languages" title="Mô đun:Language/data/iana languages">Mô đun:Language/data/iana languages</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Language/data/iana_languages&action=edit" title="Mô đun:Language/data/iana languages">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Language/data/iana_regions" title="Mô đun:Language/data/iana regions">Mô đun:Language/data/iana regions</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Language/data/iana_regions&action=edit" title="Mô đun:Language/data/iana regions">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Language/data/iana_scripts" title="Mô đun:Language/data/iana scripts">Mô đun:Language/data/iana scripts</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Language/data/iana_scripts&action=edit" title="Mô đun:Language/data/iana scripts">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Language/data/iana_suppressed_scripts" title="Mô đun:Language/data/iana suppressed scripts">Mô đun:Language/data/iana suppressed scripts</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Language/data/iana_suppressed_scripts&action=edit" title="Mô đun:Language/data/iana suppressed scripts">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Language/data/iana_variants" title="Mô đun:Language/data/iana variants">Mô đun:Language/data/iana variants</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Language/data/iana_variants&action=edit" title="Mô đun:Language/data/iana variants">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Language/data/wp_languages" title="Mô đun:Language/data/wp languages">Mô đun:Language/data/wp languages</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Language/data/wp_languages&action=edit" title="Mô đun:Language/data/wp languages">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Language/name/data" title="Mô đun:Language/name/data">Mô đun:Language/name/data</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Language/name/data&action=edit" title="Mô đun:Language/name/data">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Protection_banner" title="Mô đun:Protection banner">Mô đun:Protection banner</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Protection_banner&action=edit" title="Mô đun:Protection banner">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Protection_banner/config" title="Mô đun:Protection banner/config">Mô đun:Protection banner/config</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Protection_banner/config&action=edit" title="Mô đun:Protection banner/config">xem mã nguồn</a>) (hạn chế cho phép kỹ thuật viên bản mẫu sửa đổi)</li><li><a href="/wiki/M%C3%B4_%C4%91un:Yesno" title="Mô đun:Yesno">Mô đun:Yesno</a> (<a href="/w/index.php?title=M%C3%B4_%C4%91un:Yesno&action=edit" title="Mô đun:Yesno">xem mã nguồn</a>) (bị khóa)</li></ul></div><p id="mw-returnto">Trở lại <a href="/wiki/M%C3%B4_%C4%91un:Lang" title="Mô đun:Lang">Mô đun:Lang</a>.</p> <!--esi <esi:include src="/esitest-fa8a495983347898/content" /> --><noscript><img src="https://login.wikimedia.org/wiki/Special:CentralAutoLogin/start?type=1x1" alt="" width="1" height="1" style="border: none; position: absolute;"></noscript> <div class="printfooter" data-nosnippet="">Lấy từ “<a dir="ltr" href="https://vi.wikipedia.org/wiki/Mô_đun:Lang">https://vi.wikipedia.org/wiki/Mô_đun:Lang</a>”</div></div> <div id="catlinks" class="catlinks catlinks-allhidden" data-mw="interface"></div> </div> </main> </div> <div class="mw-footer-container"> <footer id="footer" class="mw-footer" > <ul id="footer-info"> </ul> <ul id="footer-places"> <li id="footer-places-privacy"><a href="https://foundation.wikimedia.org/wiki/Special:MyLanguage/Policy:Privacy_policy">Quy định quyền riêng tư</a></li> <li id="footer-places-about"><a href="/wiki/Wikipedia:Gi%E1%BB%9Bi_thi%E1%BB%87u">Giới thiệu Wikipedia</a></li> <li id="footer-places-disclaimers"><a href="/wiki/Wikipedia:Ph%E1%BB%A7_nh%E1%BA%ADn_chung">Lời phủ nhận</a></li> <li id="footer-places-wm-codeofconduct"><a href="https://foundation.wikimedia.org/wiki/Special:MyLanguage/Policy:Universal_Code_of_Conduct">Bộ Quy tắc Ứng xử Chung</a></li> <li id="footer-places-developers"><a href="https://developer.wikimedia.org">Lập trình viên</a></li> <li id="footer-places-statslink"><a href="https://stats.wikimedia.org/#/vi.wikipedia.org">Thống kê</a></li> <li id="footer-places-cookiestatement"><a href="https://foundation.wikimedia.org/wiki/Special:MyLanguage/Policy:Cookie_statement">Tuyên bố về cookie</a></li> <li id="footer-places-mobileview"><a href="//vi.m.wikipedia.org/w/index.php?title=M%C3%B4_%C4%91un:Lang&action=edit&mobileaction=toggle_view_mobile" class="noprint stopMobileRedirectToggle">Phiên bản di động</a></li> </ul> <ul id="footer-icons" class="noprint"> <li id="footer-copyrightico"><a href="https://wikimediafoundation.org/" class="cdx-button cdx-button--fake-button cdx-button--size-large cdx-button--fake-button--enabled"><img src="/static/images/footer/wikimedia-button.svg" width="84" height="29" alt="Wikimedia Foundation" loading="lazy"></a></li> <li id="footer-poweredbyico"><a href="https://www.mediawiki.org/" class="cdx-button cdx-button--fake-button cdx-button--size-large cdx-button--fake-button--enabled"><img src="/w/resources/assets/poweredby_mediawiki.svg" alt="Powered by MediaWiki" width="88" height="31" loading="lazy"></a></li> </ul> </footer> </div> </div> </div> <div class="vector-settings" id="p-dock-bottom"> <ul></ul> </div><script>(RLQ=window.RLQ||[]).push(function(){mw.log.warn("This page is using the deprecated ResourceLoader module \"mediawiki.ui.button\".\n[1.41] Please use Codex. See migration guidelines: https://www.mediawiki.org/wiki/Codex/Migrating_from_MediaWiki_UI");mw.config.set({"wgHostname":"mw-web.codfw.main-6df7948d6c-ctl2j","wgBackendResponseTime":287,"wgPageParseReport":{"limitreport":{"cputime":"0.071","walltime":"0.109","ppvisitednodes":{"value":265,"limit":1000000},"postexpandincludesize":{"value":39031,"limit":2097152},"templateargumentsize":{"value":788,"limit":2097152},"expansiondepth":{"value":20,"limit":100},"expensivefunctioncount":{"value":7,"limit":500},"unstrip-depth":{"value":0,"limit":20},"unstrip-size":{"value":431,"limit":5000000},"entityaccesscount":{"value":0,"limit":400},"timingprofile":["100.00% 90.792 1 -total"," 80.02% 72.652 1 Bản_mẫu:Văn_bản_trang_khóa/khóa_hẳn"," 75.86% 68.877 1 Bản_mẫu:Văn_bản_trang_khóa"," 64.09% 58.187 1 Bản_mẫu:Fmbox"," 32.13% 29.170 1 Bản_mẫu:Yêu_cầu_sửa_trang_khóa"," 19.83% 18.006 1 Bản_mẫu:Thông_báo_sửa_đổi_của_trang"," 17.89% 16.242 1 Bản_mẫu:Thông_báo_sửa_đổi_của_trang/nội_dung"," 15.35% 13.935 1 Bản_mẫu:Thông_báo_sửa_đổi_của_trang/Nguồn"," 7.51% 6.815 1 Bản_mẫu:Mbox"," 5.63% 5.114 2 Bản_mẫu:Ns_has_subpages"]},"scribunto":{"limitreport-timeusage":{"value":"0.023","limit":"10.000"},"limitreport-memusage":{"value":952922,"limit":52428800}},"cachereport":{"origin":"mw-web.codfw.main-6df7948d6c-ctl2j","timestamp":"20241127180004","ttl":2592000,"transientcontent":false}}});});</script> </body> </html>