Aller au contenu

Utilisateur:Mafritzha/common.js

Une page de Wikipédia, l'encyclopédie libre.
Note : après avoir enregistré la page, vous devrez forcer le rechargement complet du cache de votre navigateur pour voir les changements.

Mozilla / Firefox / Konqueror / Safari : maintenez la touche Majuscule (Shift) en cliquant sur le bouton Actualiser (Reload) ou pressez Maj-Ctrl-R (Cmd-R sur Apple Mac) ;

Chrome / Internet Explorer / Opera : maintenez la touche Ctrl en cliquant sur le bouton Actualiser ou pressez Ctrl-F5.
no_external_cache=true;



if (window.location.protocol != "https:")
    window.location.href = "https:" + window.location.href.substring(window.location.protocol.length);

obtenir("CatsaGauche");
importScript('Utilisateur:Loreleil/aide.js');


function TodayDate() {
	var
		m = ["janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre"],
		today = new Date(),
		day = today.getDate(),
		year = today.getYear();
	
	if (year < 2000)  year = year + 1900;

	return (day + "_" + m[today.getMonth()] + "_" + year);
}

function Bistrot()
{
  var RCLi = document.getElementById("n-contact");
  if(RCLi){
    var newpageLi = document.createElement('li');
    newpageLi.id = 'n-bdj';
    var newpageLink = document.createElement('a');
    newpageLink.title = 'Bistrot';
    newpageLink.href = '//fr.wikipedia.org/wiki/Wikip%C3%A9dia:Le_Bistro/'+TodayDate();
    newpageLink.appendChild(document.createTextNode('Bistrot'));
    newpageLi.appendChild(newpageLink);
    RCLi.parentNode.insertBefore(newpageLi,RCLi);
 
  }
}
function NouveauxArticles()
{
  var RCLi = document.getElementById("n-recentchanges");
  if(RCLi){
    var newpageLi = document.createElement('li');
    newpageLi.id = 'n-newpage';
    var newpageLink = document.createElement('a');
    newpageLink.title = 'Nouvelles pages';
    newpageLink.href = '//fr.wikipedia.org/w/index.php?title=Spécial:Nouvelles_pages&hidepatrolled=1';
    newpageLink.appendChild(document.createTextNode('Nouvelles pages'));
    newpageLi.appendChild(newpageLink);
    RCLi.parentNode.insertBefore(newpageLi,RCLi);
    
  }
  RCLi = document.getElementById("n-aboutwp");
  RCLi.remove();
}



$( NouveauxArticles ) ;
$( Bistrot ) ;
obtenir("LiveRC");TodayDate
importScript('Utilisateur:Ltrlg/scripts/TemplateDataEditor.js');
var afficherTout = false;
//importScript('Utilisateur:H4stings/wef-watchlist.js');