User:Aua/tag.js

//Simply to add tag to WikiProjects //You have to be in edit mode to try it

// if(mw.config.get('wgCanonicalNamespace') == 'Talk' && mw.config.get('wgAction')=="view") addOnloadHook(function { addPortletLink('p-cactions','javascript:addSomeText("")', 'I'); }); function addSomeText(text) { location.href=mw.config.get('wgServer')+mw.config.get('wgScript')+'?title=' + mw.config.get('wgPageName') + "&action=edit"; } if(mw.config.get('wgCanonicalNamespace') == 'Talk' && mw.config.get('wgAction')=="edit") addOnloadHook(function { addPortletLink('p-cactions','javascript:hmm("")', 'I'); }); function hmm(text) { txtb = document.getElementById('wpTextbox1'); txtb.value += text; document.getElementById('wpTextbox1').value+=""; document.getElementById('wpSummary').value= "Tagged with WikiProject Iraq"; document.getElementById('wpSave').click; } //