Changing text size with a click

D

Dan

©® said:
Just saw a nice way of changing text size
(http://www.vancouver2010.com/en/Countdown) using A+ and A- symbols.
As a newbie to things like this, is there a tutorial on how I could do
this on a personal website?
Thanks for any help!

Why reinvent the wheel? Browsers already have a method of changing
text size; for instance, in Mozilla, you can type CTRL + or CTRL -.
 
B

Beauregard T. Shagnasty

©® said:
Just saw a nice way of changing text size
(http://www.vancouver2010.com/en/Countdown) using A+ and A- symbols.
As a newbie to things like this, is there a tutorial on how I could
do this on a personal website?

I change text size by pressing Control-Plus or Control-Minus. Fluff like
that site is only necessary if the site is designed improperly to begin.
If the author had simply assigned body and content font-sizes using
percentages, none of that would be necessary, as all visitors would see
it in their preferred default size.

BTW, it doesn't work for the .. 10? .. percent with JavaScript disabled.
 
©

©®

Beauregard said:
to begin. If the author had simply assigned body and content
font-sizes using percentages, none of that would be necessary, as all
visitors would see it in their preferred default size.

Hmmn...that sounds interesting. I have never heard about percentages -
please explain or send ne to a tutorial. Thanks
 
N

Neredbojias

With neither quill nor qualm, ©® quothed:
Just saw a nice way of changing text size
(http://www.vancouver2010.com/en/Countdown) using A+ and A- symbols.

I'm a big javascript fan but I think that's just idiotic.
As a newbie to things like this, is there a tutorial on how I could do
this on a personal website?

Sure. It's the simplest parts of javascript, css, and the proper DOM.
You need to know a little of each and you can resize text, even images,
unlimitedly.
 
B

Beauregard T. Shagnasty

©® said:
Hmmn...that sounds interesting. I have never heard about percentages -
please explain or send ne to a tutorial. Thanks

The reason is when you use pixel sizing { font-size: 12px; } the most
popular browser like object, Internet Explorer, will not allow visitors
to change size, should they be vision impaired, or you pick something
too small for even people with normal vision. The solution is
{ font-size: 100%; } Assign slightly larger percentages for <Hx>
elements, and slightly smaller for legalese (85-90%).

That's it.
 
R

Richard Sexton

K

kchayka

Richard said:
http://www.wisconsinhistory.org/sitemap.asp has I think a slightly
better one in that you have some idea of the text sizes available to
you, that is you know you have 3 sizes to choose from.

Better? Hardly.

So what happens when none of their predefined choices are right for me?
The only sane solution is to set font sizes in %, then the "need" for
these silly font size adjustment kludges goes away altogether.

In the event a user hasn't already set their browser default to a
preferable size, just link to a page instructing them how to do it. Then
they've learned something they can use on any site, not just yours.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,754
Messages
2,569,527
Members
44,998
Latest member
MarissaEub

Latest Threads

Top