Changes

Jump to navigation Jump to search
1,001 bytes removed ,  14:06, 14 July 2010
no edit summary
Line 1: Line 1:  
/* Any JavaScript here will be loaded for all users on every page load. */
 
/* Any JavaScript here will be loaded for all users on every page load. */
  −
//
  −
// Insert a personalized Texttemplate into the Special:Upload edit box.
  −
//
  −
function setSpecialUploadTemplate()
  −
{
  −
var uploadURL = 'http://commons.wikimedia.org/w/index.php?title=Special:Upload&uselang=ownwork';
  −
  −
// I upload mostly my own work
  −
document.getElementById('n-upload').firstChild.href = uploadURL;
  −
  −
// preload input form
  −
if(window.location.href == uploadURL)
  −
{
  −
  var editbox = document.getElementById('wpUploadDescription');
  −
  if( editbox.value == '' )
  −
  {
  −
  editbox.value = "{"+"{Information\n"
  −
                + "|Description={{de| }} {{en| }}\n"
  −
                + "|Source=Own work\n"
  −
                + "|Date=\n"
  −
                + "|Author=[[User:Someuser|Some User]]\n"
  −
                + "|Permission=See license\n"
  −
                + "|other_versions=\n"
  −
                + "}"+"}\n\n"
  −
                + "== Licensing ==\n"
  −
                + "{"+"{self|GFDL|cc-by-sa-2.5|author=I, [[User:Someuser|Some User]]}"+"}";
  −
  }
  −
}
  −
}
  −
  −
addOnloadHook(setSpecialUploadTemplate);
  −
      
function includePage( name )
 
function includePage( name )

Navigation menu