Hello, I'm trying to setup a form so that the CSS styles can be chosen from select boxes. I want to have a font-family select box so that when an option is selected, the CSS in the page changes to that style. I would like to change the color, background-color, font-size and font-family this way.
I tried a simple bit of code but it doesn't work and I'm not that good with javascript to understand why, can anyone help? function ChangeBodyBGColor() { document.body.style.background-color=document.success.bgcolor.options[document.success.bgcolor.selectedIndex].value }