विकिपीडिया:हॉट-कैट

विकिपीडिया से

HotCat एगो जावास्क्रिप्ट प्रोग्राम हउवे जेवन विकिपीडिया की रजिस्टर्ड सदस्य लोगन के विकिपीडिया पर आसानी से श्रेणी जोड़े, हटावे आ बदले मी मदद करे ला। ई एगो अइसन औजार (गजेट) बाटे जवना में आटोमेटिक श्रेणी क नाँव पूरा होत जाला आ ए तरीका से पाहिले से मौजूद श्रेणी खोजले में बहुत सुबिधा ही जाले।

HotCat की प्रयोग क उदाहरण

इन्स्टॉल[संपादन करीं]

HotCat इन्स्टॉल करने के लिये अपनी वरीयताओं में जाएँ और "उपकरण" टैब में से "HotCat" को सक्षम करें।

दूसरा तरीका है:

  1. निम्न कोड कॉपी कर के अपनी व्यक्तिगत स्क्रिप्ट फ़ाइल में डालें:
    importScript('मीडियाविकि:Gadget-HotCat.js');
  2. पृष्ठ को सहेजें
  3. अपने ब्राउज़र की कैशे ख़ाली करके उसे रिफ़्रेश करें
  4. बस हो गया! अब आपको श्रेणियों के साथ + और - चिन्ह दिखाई देंगे। इनके प्रयोग से आप आसानी से श्रेणियाँ संपादित कर सकते हैं, बदल सकते हैं, जोड़ सकते हैं, और हटा सकते हैं।

इस्तेमाल[संपादन करीं]

जब भी कोई पन्ना लोड होता है, HotCat श्रेणियों की पट्टी ढूँढता है और अगर श्रेणियाँ दिखाई दे रही हों तो उन्हें बदलने, हटाने और अधिक श्रेणियाँ जोड़ने के लिये उस पट्टी में बटन जोड़ देता है।

HotCat द्वारा परिवर्तित श्रेणी पट्टी

नए बटन निम्न होते हैं:

  • "(-)" श्रेणी के आगे: जब इसे दबाया जाता है तो श्रेणी अपने-आप हटा दी जाती है
  • "(±)" श्रेणी के आगे: जब इसे दबाया जाता है तो श्रेणी बदलने के लिये एक डब्बा आ जाता है जिसमें वर्तमान श्रेणी का नाम पहले से लिखा होता है।
  • "(+)" श्रेणियों की सूची के अंत में: जब इसे दबाया जाता है तो नई श्रेणी जोड़ने के लिये एक डब्बा आ जाता है।
  • "(++)" बिलकुल बाईं ओर: जब इसे दबाया जाता है तो HotCat बहु बदलाव मोड (multi-change mode) में चला जाता है, जिसमें आप पृष्ठ को सहेजने से पहले एक साथ कई श्रेणियाँ बदल सकते हैं।

अगर HotCat ये जान पाता है कि श्रेणियाँ पृष्ठ में सीधे नहीं हैं, बलकी किसी साँचे में से (या किसी ट्रान्स्क्लूड हुए पन्ने में से) हैं; तो HotCat उस श्रेणी में बदलाव के लिये बटन नहीं जोड़ता है। HotCat से केवल वही श्रेणियाँ बदली जा सकती हैं जो पृष्ठ में सीधे जोड़ी गयी हैं।

श्रेणी हटाना[संपादन करीं]

किसी भी श्रेणी को हटाने के लिये उसके साथ दिये "(-)" बटन पर क्लिक करें। अगर पन्ने में वह श्रेणी सीधे जोड़ी गयी है तो HotCat उसे अपने-आप हटा देगा। इसके लिये HotCat निम्न कार्य करेगा:

  1. आपके ब्राउज़र में एक नई विंडो अथवा नया टैब खोलेगा पन्ने के सम्पादन के लिये
  2. पूरा सम्पादन फ़ॉर्म छुपा देगा, और आप सम्पादन नहीं कर पाएँगे
  3. पन्ने में सम्पादन कर HotCat उसमें से श्रेणी हटाएगा
  4. पन्ने को सहेजेगा

श्रेणी बदलना[संपादन करीं]

कोई भी श्रेणी बदलने के लिये उसके साथ दिये "(±)" बटन पर क्लिक करें। इससे एक डब्बा खुलेगा जिसमें आप उस श्रेणी का नया नाम डाल सकते हैं।

श्रेणी जोड़ना[संपादन करीं]

श्रेणी जोड़ने के लिये श्रेणी-पट्टी के अंत में दिये "(+)" बटन पर क्लिक करें। इससे एक डब्बा खुलेगा जिसमें आप नयी श्रेणी का नाम डाल सकते हैं।

इनपुट डब्बा[संपादन करीं]

HotCat का इनपुट डब्बा
HotCat का इनपुट डब्बा

HotCat का इनपुट डब्बा बहुत सरल है। इसमें श्रेणी का नाम डालने के लिये एक टेक्स्ट फ़ील्ड है, एक संकेतक आइकन है, और "OK" और "Cancel" बटन हैं।

यह टेक्स्ट फ़ील्ड विकिपीडिया की इनपुट प्रणाली नारायम के साथ काम करती है।

संकेतक आइकन इस बात को दर्शाता है कि श्रेणी का जो नाम डाला गया है, वह श्रेणी मौजूद है या नहीं। आइकन का अर्थ है कि ऐसी कोई श्रेणी फ़िलहाल मौजूद नहीं है। आप फिर भी श्रेणी जोड़ सकते हैं, पर वो एक लाल कड़ी (redlink) की तरह दिखाई देगी। यदि आप कोई ऐसी श्रेणी जोड़ते हैं तो जोड़ने के बाद उस लाल कड़ी पर क्लिक करके उसका एक छोटा स वर्णन दें और उसे भी कुछ अन्य श्रेणियों में डाल दें। आइकन का अर्थ है कि जो नाम आपने इनपुट किया है, उस नाम की श्रेणी पहले से मौजूद है।

HotCat का इनपुट डब्बा सुझावों की सूची के साथ
HotCat का इनपुट डब्बा सुझावों की सूची के साथ

जब आप टाइप कर रहे होंगे तो HotCat इनपुट डब्बे के ऊपर या नीचे सुझावों की एक सूची दिखाएगा। इनमें से किसी सुझाव को क्लिक करने पर वह इनपुट डब्बे में कॉपी हो जाएगा। किसी सुझाव पर डबल-क्लिक करना उसपर क्लिक करके "OK" दबाने के समान है: HotCat अपने-आप क्लिक करी हुई सुझाव श्रेणी जोड़ देगा। सुझाव सूची में सुझाव चुने हुए सर्च इंजन के अनुसार आते हैं। सर्च इंजन चुनने के विकल्प सुझाव सूची और इनपुट डब्बे के बीच में एक ड्रॉप-डाउन मीनू की तरह दिखाई देते हैं।

HotCat का इनपुट डब्बा सुझावों की सूची के साथ
HotCat का इनपुट डब्बा सुझावों की सूची के साथ

यहाँ दिखाए उदाहरण में HotCat को "Alps of" इनपुट दी गई है। इस इनपुट पर HotCat सुझावों की एक सूची देता है। सुझावों में से सबसे पहला सुझाव अपने-आप इनपुट डब्बे में कॉपी हो जाएगा। यह अपने-आप कॉपी किया गया हिस्सा सिलेक्ट हुआ होगा ताकि आपके टाइप करते ही उस अपने-आप डाले हिस्से की जगह आपका लिखा आ जाए। जैसे ही आप आगे लिखते हैं, HotCat सुझाव सूची को अपडेट कर देता है। इस उदाहरण में "S" टाइप करते ही HotCat सुझाव सूची अपडेट करता है और नए सुझाव दिखाता है।

किसी भी सुझाव पर क्लिक करने पर वह सुझाव इनपुट डब्बे में कॉपी हो जाएगा और यदि उस इनपुट के लिये कोई अन्य सुझाव होंगे तो आएँगे; और यदि नहीं होंगे तो सुझाव सूची बंद हो जाएगी।

"Cancel" दबाने पर HotCat श्रेणी नहीं जोड़ेगा, और "OK" दबाने पर इनपुट डब्बे में उस समय जो भी होगा, वही श्रेणी जोड़ देगा।

अनेक श्रेणियाँ बदलना[संपादन करीं]

बहु-बदलाव मोड में श्रेणियाँ तभी सहेजी जाती हैं जब "सहजें" बटन पर क्लिक किया जाए।

HotCat में एक बहु-बदलाव मोड है जिसके द्वारा सहेजने से पहले अनेक श्रेणियों में एक साथ परिवर्तन किया जा सकता है।

अनेक श्रेणियों को एक साथ बदलने के लिये बिलकुल बाईं ओर के "++" बटन को दबाएँ। इसे दबाते ही इसकी जगह "सहेजें" का एक बटन आ जाएगा। इस बटन के आने के बाद आप श्रेणियों में जितने चाहें परिवर्तन कर सकते हैं। ये परिवर्तन तभी सहेजे जाएँगे जब "सहेजें" बटन पर क्लिक किया जाए। यदि श्रेणियों में कोई परिवर्तन नहीं किया गया हो तो यह बटन अपने-आप ही अक्षम होता है। श्रेणियों में परिवर्तन होते ही यह बटन सक्षम हो जाता है।


In multi-change mode, changes are reflected on the page view, but are saved only when the "save" button is clicked.

यदि एक श्रेणी में परिवर्तन करते समय आप किसी दूसरी श्रेणी को भी परिवर्तित करने का प्रयत्न करते हैं तो बहु-बदलाव मोड अपने-आप सक्षम हो जाता है।

इस मोड में किसी भी श्रेणी में परिवर्तन करने के पश्चात "OK" दबाने पर वह श्रेणी नहीं सहेजी जाएगी, बलकी तभी सहेजी जाएगी जब "सहेजें" पर क्लिक किया जाए। इसके अतिरिक्त, जिन भी श्रेणियों में बदलाव किया गया है, उनके आगे HotCat एक "(×)" का बटन जोड़ देता है। इसे दबाने पर उस श्रेणी में किये गए परिवर्तन ख़ारिज हो जाते हैं। हटाई गई श्रेणियाँ इस मोड में कटी हुई नज़र आती हैं। साथ ही, जो श्रेणी बदलाव सहेजे नहीं गए हैं, उनका बैकग्राउंड रंग सहेजी हुई श्रेणियों से हलका-सा फ़र्क नज़र आता है।

जब "सहेजें" बटन दबाया जाता है तो HotCat सभी बदलाव कर के संपादन विंडो खोलता है। इस संपादन विंडो में बदलाव किये जा चुके होते हैं और संपादन सारांश पहले से भरा होता है। परंतु यह अपने-आप सहेजे नहीं जाते हैं। इन्हें सहेजने से पहले यह जाँच लें कि HotCat ने वही किया है जो आपने कहा था (जाँच लें कोई गड़बड़ ना हुई हो)। जाँचने के पश्चात बदलाव सहेजने के लिये "लेख सहेजें" बटन पर क्लिक करें।

ध्यान दें कि बहु-बदलाव मोड में HotCat कभी अपने-आप बदलाव नहीं सहेजेगा। आपको बहु-बदलाव मोड के बदलाव सहेजने से पहले हमेशा जाँच लेने चाहियें।

Advanced usage tips[संपादन करीं]

Avoid auto saving[संपादन करीं]

Normally HotCat automatically saves your edit. However sometimes you might wish to go to the edit box instead to verify and then execute the save yourself. Instead of clicking OK, click OK while you have the modifier key pressed. On Windows computers this is the ctrl-key, on Apple computers it should be the command-key.

Sort keys[संपादन करीं]

You can even give a sort key together with the category. Just write after the category name a vertical bar ("|"), followed by the sort key under which the page shall be sorted within that category's list.

  • Input "Foo" will add a new category "Foo" without sort key, or change an existing category to "Foo", preserving the sort key.
  • Input "Foo|Key" will add a new category "Foo" or change an existing category to "Foo", using the given sort key "Key" in both cases.
  • Input "Foo|" (with a trailing vertical bar) will add a new category "Foo" without sort key, or change an existing category to "Foo", removing any sort key the changed category might have had.

Easy categorizing to child or parent categories[संपादन करीं]

Users who do a lot of category maintenance might want to enable the quick access links for categorizing to child or parent categories. To enable this add the following to your javascript page:

var hotcat_use_category_links = true;

The following controls will be added:

  • "(↓)" after a category: when clicked, the input field is opened, and a list of available subcategories is displayed.
  • "(↑)" after a category: when clicked, the input field is opened, and a list of available parent categories is shown.

Note that the "(↓)" and "(↑)" links are shown only for existing categories. Red-linked categories, i.e. non-existing categories, can have neither parent nor subcategories, and thus showing these links wouldn't make sense. Also note that it is possible that only the input box is shown when these links are clicked, but no list. That indicates that this category does not have parent categories or subcategories, respectively. See also "Search engines" below.

Search engines[संपादन करीं]

Between the suggestion list and the text input field, there is a search engine selector to select the search method which populates the suggestion list. HotCat support any number of search engines.

The MediaWiki servers offer two general ways to search for categories. The first is through the page list of the wiki. This list is always up to date, but is strictly alphabetic and also case-sensitive, so "similar" suggestions (for instance, suggesting "Bláhnjúkur" when "Blahn" was entered) are not shown. The second search engine is the search index that is also used by the "search" box on all pages. It does find "similar" suggestions and is not case-sensitive, but as its index is updated only at intervals, it may not show newly created categories.

HotCat by default combines these two search engines to get the best of both worlds: similar suggestions and newly created categories. However, to do so, it must make two requests to the server. Normally, that's not a problem, but if it turns out to be too slow on a slow connection, you can use the engine selector to choose which search engine you want to use. It is also possible to configure which search engine HotCat should use by default.

In addition to these general searches, HotCat also provides two additional, more specialized search engines. A first one can be used to search for subcategories of the category given by the current input. A second one returns the parent categories of the category given by the current input. Both engines may return empty results, in which case no suggestion list is shown. (For instance, if the current input is a name of a non-existing category, or if a category has no subcategories). In this case, the search engine is automatically reset to the default search engine after the first non-deleting input.

Note that there is no way to "page" through a list of subcategories. The script just tries to get as many subcategories as it can (normally at most 500, the limits for administrators are somewhat higher). Subcategory queries can also be slow if a category contains many items (not just many subcategories), and the input field is made non-editable for the time of the request. If it doesn't become editable in reasonable time, just click cancel.

For the technically inclined: the problem is that subcategory continuation queries appear not to work in the MediaWiki API. On the (hidden) category Category:Media with locations, the API returns (with a limit of 5000) only the first 1540 subcategories of more than 4800 that exist, and continuation queries seem to return no further subcategories at all. Related bug reports on this are bugzilla:1211 and bugzilla:23682. Until this is fixed, there will be no paging through subcategories in HotCat.

User configuration[संपादन करीं]

You can adapt many of the aspects of HotCat. Please see its full documentation page on Wikimedia Commons.

HotCat was initially developed for Wikimedia Commons by Magnus Manske and later adapted and improved by many users, including, but not limited to प्रयोगकर्ता:Lupo, प्रयोगकर्ता:Dschwen, प्रयोगकर्ता:TheDJ, प्रयोगकर्ता:Superm401 and प्रयोगकर्ता:Merlissimo.

The version on English Wikipedia is the same as the version on Commons but with a different default user configuration.

  • Safari 3 & 4: Tested and fully working
  • Safari 2: Has a non-harmful issue with displaying the "change" (±) link.
  • Firefox 2 & 3: Tested and fully working
  • IE 6, 7 & 8: Tested and fully working
  • Google Chrome: Tested and fully working
  • Opera: Tested and fully working

It is also tested and confirmed to be working in combination with Navigation popups, wikEd and the modern skin.

Code Result
{{प्रयोगकर्ता:Scarce/Userboxes/HotCat}} प्रयोगकर्ता:Scarce/Userboxes/HotCat Usage
{{प्रयोगकर्ता:Cj005257/userbox/hotcat}} प्रयोगकर्ता:Cj005257/userbox/hotcat Usage

Also, there is the HotCat topicon. {{HotCat topicon}}.