August 19, 2009

Javascript Tutorial 14: Style A String


var test="this is just a test";
document.write(word.toUpperCase());

To upper case is not the only feature of javascript but


document.write(word.bold());
document.write(word.strike());


document.write(word.fontcolor("Red"));
If you want to change the color, you would have to put it in the parenthesis. That is where multiple properties elements goes.



Powered by ScribeFire.

No comments:

Post a Comment