Can anyone give me some info on how to set this up in website... where I can find some code for this?
Thanks
Can anyone give me some info on how to set this up in website... where I can find some code for this?
Thanks
Certainly, if you give us some info as to what on earth you're actually trying to do. A single function name isn't much of a giveaway, you know.
Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!
No problem.... I want to have the ability for my visitors to enlarge the font size. I saw a website that offered that. They actually had two larger sizes that the people could click on to use. http://abcnews.go.com/Travel/story?id=1486744&page=1
You will notice that it's under the banner at the top on the right-hand side.
Thanks.
Most browsers already implement this. In Firefox, it's under View->Text Size.
Nevertheless, this ought to work:
Change "18pt" in all links to font sizes better suited to your site as a default. Tested only in Firefox, and that with only a very simple DOM.Code:<a href="javascript:void(0);" onclick=" var fs = document.body.style.fontSize; document.body.style.fontSize = ( isNaN(parseFloat(fs)) ? '18pt' : (parseFloat(fs) + 2) + fs.substring(parseFloat(fs).toString().length) ); ">Increase Font Size</a> <a href="javascript:void(0);" onclick=" var fs = document.body.style.fontSize; document.body.style.fontSize = ( isNaN(parseFloat(fs)) ? '18pt' : (parseFloat(fs) - 2) + fs.substring(parseFloat(fs).toString().length) ); ">Decrease Font Size</a> <a href="javascript:void(0);" onclick=" document.body.style.fontSize = '18pt'; ">Default Font Size</a>
Last edited by Twey; 01-15-2006 at 12:48 AM.
Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!
Bookmarks