Content deleted Content added
use .text(), clean up |
major changes in stubtagtab and stubtagmenurender |
||
Line 5:
function stubtagtab() {
var h, hb, newa;
// A list of subpages of WikiProject Stub sorting/Stub types/ that are relevant to this
var a = ['Commerce', 'Culture', 'Education', 'Geography', 'Government, law, and politics', 'History', 'Leisure', 'Military and weaponry', 'Miscellaneous', 'Organizations', 'People', 'Religion, mythology, faiths, and beliefs', 'Science', 'Sports', 'Technology', 'Transport'];
h.attr({
});
for (var i = 0; i < a.length; i++
newa = $("<a href="#"></a>");
newa.click(function (e) {
e.preventDefault();
stubtagmenu(a[i]);
});
newa.text("a[i]");
h.append(newa);
if ((i + 1) < a.length) h.append(" • ");
}
hb = $("<div>");
h += "</div><div id='stubtagmenudiv' style='color: #000000; background-color: #fffff8;'></div>";▼
hb.attr({
▲
});
h.after(hb);
$("#contentSub").html(h);
}
Line 24 ⟶ 36:
index = link.indexOf("Template:")
if (index === -1) {
$($(this).text()).clone().wrap('<div>').parent().html();
} else {
$(this).attr("href", mw.config.get("wgServer") + mw.config.get("wgScript") + "?title=" + encodeURIComponent(mw.config.get("wgPageName"))
|