Utente:Genuzzu/monobook.js: differenze tra le versioni

Vai alla navigazione Vai alla ricerca
Contenuto aggiunto Contenuto cancellato
(Creata pagina con '//YEAH →‎Trib plus: function tribPlusInit() { var $processingArticles = $('.LightVotingTable'); $processingArticles.each(function() { alert($('tr:eq(4) td ol li',...')
 
Nessun oggetto della modifica
Riga 6: Riga 6:
var $processingArticles = $('.LightVotingTable');
var $processingArticles = $('.LightVotingTable');
$processingArticles.each(function() {
$processingArticles.each(function() {
alert($('tr:eq(4) td ol li', this).length);
var forDelete = $('tr:eq(4) td:eq(0) ol li', this).length;
var forRestwat = $('tr:eq(4) td:eq(1) ol li', this).length;
var forSave = $('tr:eq(6) td ol li', this).length;
$('tr:eq(3) td:eq(0) span b').append('<i>(' + forDelete + ')</i>');
$('tr:eq(3) td:eq(1) span b').append('<i>(' + forRestwat + ')</i>');
$('tr:eq(5) td span b').append('<i>(' + forSave + ')</i>');
});
});
}
}

Versione delle 21:23, 5 dic 2012

//YEAH

/* Trib plus */

function tribPlusInit() {
  var $processingArticles = $('.LightVotingTable');
  $processingArticles.each(function() {
    var forDelete = $('tr:eq(4) td:eq(0) ol li', this).length;
    var forRestwat = $('tr:eq(4) td:eq(1) ol li', this).length;
    var forSave = $('tr:eq(6) td ol li', this).length;
    $('tr:eq(3) td:eq(0) span b').append('<i>(' + forDelete + ')</i>');
    $('tr:eq(3) td:eq(1) span b').append('<i>(' + forRestwat + ')</i>');
    $('tr:eq(5) td span b').append('<i>(' + forSave + ')</i>');
  });
}

if (wgPageName == 'Nonciclopedia:Tribunale') {
  $(document).ready(tribPlusInit);
}