PDA

View Full Version : URG: Changing fontFamily and fontSize of another frame


Pennes
12-26-2002, 09:41 PM
im supposed to get this script up by tomorow, and i got jammed by semantics error. i dont know how to define fontfamily and fontcolor in another frame. right now i use:

top.frames.main.body.style.fontFamily=document.dv.font.value;
top.frames.main.body.style.fontSize=document.dv.size.value;

(document.dv.size.value is a <select name="size"> in a form named "dv")
i get error. i also used main.style.fontsize, main.body.fontsize, main.fontsize, ... and some other combinations

to any helpers out there, i thank in advance!

ACJavascript
12-27-2002, 01:03 AM
Try this..

top.frames.main.body.style.fontSize=document.dv.size.options[document.dv.size.selectedIndex].value


Hope is works hehe :D