MediaWici:Monobook.js
Sylwer: Ar ôl cyhoeddi, efallai y bydd rhaid i chi fynd heibio celc eich porwr er mwyn gweld y newidiadau.
- Firefox / Safari: Pwyswch Shift wrth glicio Ail-lwytho/Reload, neu pwyswch naill ai Ctrl-F5 neu Ctrl-R (⌘-R ar Mac);
- Google Chrome: Pwyswch Ctrl-Shift-R (⌘-Shift-R ar Mac)
- Internet Explorer: Pwyswch Ctrl wrth glicio Adnewyddu/Refresh, neu pwyswch Ctrl-F5.
- Opera: Pwyswch Ctrl-F5.
/* add edit tabs at bottom of the screen as well as the top */
function morelinks() {
var tabs = document.getElementById('p-cactions').cloneNode(true);
// don't use the same ids twice- replace the p-cactions id and prepend 'mytabs-' to the li's tabs.id = 'mytabs';
// needs this to be set from js, it ignores the css width for some reason tabs.style.width = '100%';
var listitems = tabs.getElementsByTagName('LI');
for (i=0;i<listitems.length;i++) {if(listitems[i].id) listitems[i].id = 'mytabs-' + listitems[i].id;}
// drop them at the bottom of the content area document.getElementById('column-content').appendChild(tabs);
}
if (window.addEventListener) window.addEventListener("load",morelinks,false);
else if (window.attachEvent) window.attachEvent("onload",morelinks);
if (window.showModalDialog && document.compatMode && document.compatMode == "CSS1Compat")
{
var oldWidth;
var docEl = document.documentElement;
function fixIEScroll()
{
if (!oldWidth || docEl.clientWidth > oldWidth)
doFixIEScroll();
else
setTimeout(doFixIEScroll, 1);
oldWidth = docEl.clientWidth;
}
function doFixIEScroll() {
docEl.style.overflowX = (docEl.scrollWidth - docEl.clientWidth < 4) ? "hidden" : "";
}
document.attachEvent("onreadystatechange", fixIEScroll);
attachEvent("onresize", fixIEScroll);
}
// END Dynamic Navigation Bars
// ============================================================
var isDiff = (document.location.search && (document.location.search.indexOf("diff=") != -1 || document.location.search.indexOf("oldid=") != -1));
if (mw.config.get('wgIsMainPage') && !isDiff) {
mw.util.addCSS(' #siteSub, #contentSub, h1.firstHeading { display: none !important; }');
}