MediaWiki:Common.js: Unterschied zwischen den Versionen

Keine Bearbeitungszusammenfassung
Keine Bearbeitungszusammenfassung
 
Zeile 19: Zeile 19:
window.addEventListener('load', function() {
window.addEventListener('load', function() {
console.log("alles geladen")
console.log("alles geladen")
sortables_init();
// sort the first sortable table; change [0] to sort other tables.
tab = document.getElementsByTagName("table")[0];
// sort by the first column; change [0] to sort by other columns.
hdr = tab.getElementsByTagName("th")[0];
// get the sort button link
lnk = hdr.getElementsByTagName("a")[0];
ts_resortTable(lnk);
})
})


Zeile 39: Zeile 31:
// your code
// your code
console.log("und jetzt?");
console.log("und jetzt?");
sortables_init();
// sort the first sortable table; change [0] to sort other tables.
tab = document.getElementsByTagName("table")[0];
// sort by the first column; change [0] to sort by other columns.
hdr = tab.getElementsByTagName("th")[0];
// get the sort button link
lnk = hdr.getElementsByTagName("a")[0];
ts_resortTable(lnk);
});
});