မီႇတီႇယႃႇဝီႇၶီႇ:Gadget-SpecialSearch.js
Appearance
မၢႆတွင်း: ဝၢႆးသေသိမ်းပၼ်ယဝ်ႉ၊ တွၼ်ႈတႃႇ ၸဝ်ႈၵဝ်ႇ တေႁၼ်လႆႈ လွင်ႈလႅၵ်ႈလၢႆႈၼၼ်ႉ ၸဝ်ႈၵဝ်ႇတေၸၢင်ႈလႆႈလတ်းၶၢမ်ႈ ၶႅတ်ႉၶျ် တူဝ်ပိုတ်ႇဝႅပ်ႉၸဝ်ႈၵဝ်ႇယဝ်ႉ။
- ၽွင်းမိူဝ်ႈတိုၵ်ႉၼဵၵ်း Reload တီႈ Firefox / Safari: ၼၼ်ႉ ၼဵၵ်းဝႆႉပႃး Shift ၊ဢမ်ႇၼၼ် ၼဵၵ်းပၼ် Ctrl-F5 ဢမ်ႇၼၼ် Ctrl-R (တီႈၼႂ်း Mac ၼႆ ၼဵၵ်းပၼ်⌘-R)
- တီႈၼႂ်း Google Chrome: ၼဵၵ်းပၼ် Ctrl-Shift-R (တီႈၼႂ်း Mac ၼႆႉ ၼဵၵ်းပၼ်⌘-Shift-R )
- ၽွင်းမိူဝ်ႈ တိုၵ်ႉၼဵၵ်း Refreshတီႈ Internet Explorer/ Edge: ၼဵၵ်းဝႆႉပၼ် Ctrl ဢမ်ႇၼၼ် ၼဵၵ်းပၼ် Ctrl-F5
- တီႈၼႂ်း Opera: ၵႂႃႇၸူးတီႈ Menu → Settings (ပေႃးပဵၼ်တီႈၼႂ်း Mac ၸိုင် Opera → Preferences ) သေ သိုပ်ႇၵႂႃႇ Privacy & security → Clear browsing data → Cached images and files ၼၼ်ႉလႄႈ။
/** Change Special:Search to use a drop-down menu *******************************************************
*
* Description: Change Special:Search to use a drop-down menu, with the default being
* the internal MediaWiki engine
* Created and maintained by: [[User:Gracenotes]]
*/
function SpecialSearchEnhanced() {
var createOption = function(site, action, mainQ, addQ, addV) {
var opt = document.createElement('option');
opt.appendChild(document.createTextNode(site));
window.searchEngines.push([action, mainQ, addQ, addV]);
return opt;
}
if (document.forms.powersearch)
var searchForm = document.forms.powersearch;
if (document.forms.search)
var searchForm = document.forms.search;
if (searchForm.lsearchbox) {
var searchBox = searchForm.lsearchbox;
} else {
var searchBox = searchForm.search;
}
var selectBox = document.createElement('select');
selectBox.id = 'searchEngine';
searchForm.onsubmit = function() {
var optSelected = window.searchEngines[document.getElementById('searchEngine').selectedIndex];
searchForm.action = optSelected[0];
searchBox.name = optSelected[1];
searchForm.title.value = optSelected[3];
searchForm.title.name = optSelected[2];
}
selectBox.appendChild(createOption('English Wikibooks', mw.config.get( 'wgScript' ), 'search', 'title', 'Special:Search'));
selectBox.appendChild(createOption('Google', 'https://www.google.com/search', 'q', 'sitesearch', 'en.wikibooks.org'));
selectBox.appendChild(createOption('Yahoo', 'https://search.yahoo.com/search', 'p', 'vs', 'en.wikibooks.org'));
selectBox.appendChild(createOption('Bing', 'https://www.bing.com/search', 'q', 'q1', 'site:https://en.wikibooks.org'));
selectBox.appendChild(createOption('Wikiwix', 'http://www.wikiwix.com/', 'action', 'disp', 'book'));
selectBox.appendChild(createOption('Exalead', 'https://www.exalead.com/', 'q', 'site', 'en.wikibooks.org'));
searchBox.style.marginLeft = '0px';
if (document.getElementById('loadStatus')) {
var lStat = document.getElementById('loadStatus');
} else {
var lStat = searchForm.title;
if( typeof lStat === 'object' && typeof lStat.length === 'number' ) lStat = lStat[0];
}
lStat.parentNode.insertBefore(selectBox, lStat);
}
window.searchEngines = [];
// Script is specific to Special:Search
if ( mw.config.get( 'wgCanonicalSpecialPageName' ) === 'Search'){
$(SpecialSearchEnhanced);
}