User:LOL/textboxfont.js

var iTextboxFont = 0; var textboxFonts = new Array; textboxFonts.push('Courier New'); textboxFonts.push('Verdana');

function toggleTextboxFont { document.editform.wpTextbox1.style.fontFamily = textboxFonts[iTextboxFont]; iTextboxFont = (iTextboxFont + 1) % textboxFonts.length; }

addOnloadHook(function {   if(document.forms.editform) {        addPortletLink('p-tb', 'javascript:toggleTextboxFont', 'Textbox font', 't-textboxfont', 'Toggle textbox font between ' + textboxFonts.toString, , );    } });