सदस्य:Udamkhor/vector.js

विकिपीडिया, मुक्‍त ज्ञानकोशातून

नोंद: साठवून ठेवल्यानंतर बदल पहाण्यासाठी कदाचित तुमच्या ब्राऊजरच्या कॅचेला बायपास करावे लागेल.

  • फ़ायरफ़ॉक्स / सफ़ारी: धरुन ठेवा Shift टिचकी मारताना Reload, किंवा हे दाबताना Ctrl-F5 किंवा Ctrl-R (⌘-R मॅकवर)
  • गुगल क्रोम: दाबा Ctrl-Shift-R (⌘-Shift-R मॅकसाठी)
  • ओपेरा: कडे जा Menu → Settings (ओपेरा → पसंतीक्रम on a Mac) आणि मग गोपनियता आणि सुरक्षा → ब्राउजिंग डाटा काढून टाका → कॅचे छायाचित्रे आणि धारिणी.
//image delere
/**** quick image delete ****/
importScript('User:Howcheng/quickimgdelete.js');
//mw.loader.load("//en.wikipedia.org/w/index.php?title=User:Howcheng/quickimgdelete.js&action=raw&ctype=text/javascript");
importScript('सदस्य:Rahuldeshmukh101/image-cert.js');
 
//टुल बार
importScript('User:Odie5533/SnipManager.user.js');
 
mw.loader.load("//en.wikipedia.org/w/index.php?title=User:Odie5533/SnipManager.user.js&action=raw&ctype=text/javascript");
 
// A small piece of JS writen by [[User:MatthewFenton]], This is my first piece of JS.
function welcome() {
    if (document.title.indexOf('Editing User talk:') == 0) {
        document.editform.wpTextbox1.value = document.editform.wpTextbox1.value + '==' + 'Welcome' + '==\n' + '{{subst:User:' + 'MatthewFenton/Welcome}}\n~~' + '~~';
        document.editform.wpSummary.value = 'Welcome a user to Wikipedia using JS WW';
    }
}
function welcome_tab() {
    add_link('javascript:welcome()', 'Welcome');
}
 
if (document.title.indexOf('Editing User talk:') == 0) {
 addOnloadHook(welcome_tab);
}
 
 
 
// [[wikipedia:User:Lupin/popups]]
mw.loader.load("//en.wikipedia.org/w/index.php?title=User:Lupin/popups.js&action=raw&ctype=text/javascript");
 
//editcounter
mw.loader.load("//en.wikipedia.org/w/index.php?title=User:Lupin/editcount.js&action=raw&ctype=text/javascript");
 
importScript('सदस्य:Rahuldeshmukh101/redhot.js');
// tree code
 
function AppendCategoryTreeToSidebar() {
    try {
        var node = document.getElementById( "p-tb" )
                           .getElementsByTagName('div')[0]
                           .getElementsByTagName('ul')[0];
 
        var aNode = document.createElement( 'a' );
        var liNode = document.createElement( 'li' );
 
        aNode.appendChild( document.createTextNode( 'CategoryTree' ) );
        aNode.setAttribute( 'href' ,  '[[mr.wikipedia.org/wiki/विशेष:वर्गवृक्ष]]');
        liNode.appendChild( aNode );
        liNode.className = 'plainlinks';
        node.appendChild( liNode );
    } catch(e) {
        // lets just ignore what's happened
        return;
    }
}
//tree code end




$(function ($) {
  var translate = {
    'mr': {
      removeinterwikis: "इतर भाषा काढून टाका",
      summary: "इतर भाषांचे विलिनीकरण ([[d:WD:I|थेट विकिडाटा]])"
    },
    'hi': {
      removeinterwikis: "अन्य भाषा कड़ियाँ निकालो",
      summary: "अन्य भाषा कड़ियाँ निकाली([[d:WD:I|Live Wikidata]])"
    }
  }
  var namespace = mw.config.get('wgNamespaceNumber'), 
    lang = mw.config.get('wgPageContentLanguage'),
    m = translate[ lang ] || translate.en,
    page = namespace === 0 ? mw.config.get('wgTitle') : mw.config.get('wgFormattedNamespaces')[ namespace ] + ':' + mw.config.get('wgTitle').replace(/\/doc$/, ''),
    editbox = document.getElementById( "wpTextbox1" );
  function removeInterwikis() {
    document.body.style.cursor = "wait";
    $.ajax({
      url: '//www.wikidata.org/w/api.php',
      data: {
        'format': 'json',
          'action': 'wbgetentities',
          'sites': mw.config.get('wgDBname'),
          'titles': page,
          'props': 'sitelinks',
          'languages': lang
      },
      dataType: 'jsonp',
      success: function (data) {
        if (data.success) {
          for (var i in data.entities) {
            if ( i != -1 ) {
              var item = data.entities[i] && data.entities[i].sitelinks;
              if ( item ) {
                for ( var i in item ) {
                  var interw = "[[" + item[ i ].site.split("wiki")[0].replace(/_/g,"-") + ":" + item[ i ].title + "]]";
                  editbox.value = editbox.value.replace( interw + "\n", "" ).replace( interw, "" );
                }
              }
            }
            var editsum = document.getElementById("wpSummary");
            editsum && (editsum.value += ( m.summary || '' ));
          }
        }
        document.body.style.cursor = "";
      }
    });
  }
  editbox && $( mw.util.addPortletLink( 'p-cactions', '#', m.removeinterwikis ) ).on( "click", removeInterwikis);
});

mw.loader.load('//meta.wikimedia.org/w/index.php?title=User:udamkhor/थेट विकिडाटा.js&action=raw&ctype=text/javascript');