Module:Sort title/doc
यह मॉड्यूल:Sort title हेतु प्रलेख पृष्ठ है
इस लुआ मोड्यूल का इस्तेमाल कई बड़ी संख्या के पृष्ठों में किया जा रहा है। बड़े पैमाने पर व्यवधान और अनावश्यक सर्वर लोड से बचने के लिए, किसी भी बदलाव के पहले इस साँचे के /प्रयोगपृष्ठ उपपृष्ठ या अपने उपयोगकर्ता स्थान पर उसे जांच कर देख ले। जांचे गये बदलावों को इस साँचे में एक बार में जोड़ा जा सकता है।अन्य उपयोगकर्ताओं के खातिर, बदलाव करने से पहले उससे सम्बंधित बात-चीत वार्ता पृष्ठ पर करें। |
This module depends on the following other modules: |
Module:Sort title is used to create sortkeys for pages.
What it does
संपादित करेंThe module preforms the following checks:
- If the first word of the title is an article, it moves it to the end of the title. For example:
The Avengers
will have a sortkey ofAvengers, The
. - If the title is disambiguated and the first word of the disambiguation is an article, it moves it to the end of the disambiguation. For example:
Pilot (The Flash)
will have a sortkey ofPilot (Flash, The)
. - If the title is disambiguated and the first word of the title and the disambiguation is an article, both of the above changes will occur. For example:
The End (A Series of Unfortunate Events)
will have a sortkey ofEnd, The (Series of Unfortunate Events, A)
. - If the title is a number which is separated by a commas, it removes the commas. For example:
4,722 Hours
will have a sortkey of4722 Hours
.
Usage
संपादित करेंFrom template:
{{#invoke:Sort title|getSortKey}}
{{#invoke:Sort title|getDefaultSort}}
From module:
local sortkeyModule = require('Module:Sort title')
local sortkey = sortkeyModule._getSortKey()
Function list
संपादित करेंFunction | Explanation |
---|---|
getSortKey
|
Returns a sortkey |
getDefaultSort
|
Returns a DEFAULTSORT string |