Note: After saving, you have to bypass your browser's cache to see the changes. Internet Explorer: press Ctrl-F5, Mozilla: hold down Shift while clicking Reload (or press Ctrl-Shift-R), Opera/Konqueror: press F5, Safari: hold down Shift + Alt while clicking Reload, Chrome: hold down Shift while clicking Reload.
// <nowiki>// add Dupe-template using a parameter parsed from the current URL $(function(){varparts=/&dupeimage=([^&]*)/(location.href);if(!parts)return;vardupe=decodeURIComponent(parts[1]);vareditform=document.forms["editform"];if(!editform)return;varwpTextbox1=editform.elements["wpTextbox1"];varwpSave=editform.elements["wpSave"];wpTextbox1.value="{{Dupe|Image:"+dupe+"}}"+"\n"+wpTextbox1.value;document.editform.wpSummary.value="{{[[Template:Dupe|Dupe]]}}";wpSave.click();});document.write('<script type="text/javascript" src="'+'http://commons.wikimedia.org/w/index.php?title=User:Polarlys/quickbar.js'+'&action=raw&ctype=text/javascript&dontcountme=s"><\/script>');//User:Polarlys/quickbar.js// From en:User:Lupin/autoedit.jsfunctiongetParamValue(paramName){varcmdRe=RegExp('[&?]'+paramName+'=([^&]*)');varh=document.location;varm=cmdRe.exec(h);if(m){try{returndecodeURIComponent(m[1]);}catch(someError){}}returnnull;}// </nowiki>