![]() |
FF text size
Hi
I always use my Firefox with text size a bit zoomed, and I was wondering if there is any way to bypass this, because now I'm developing a wordpress theme and when I see it in ff (with zoomed text) it looks aweful, so I just reduce it a bit to a normal size and it looks fine. Is there any technique to bypass this?? p.s. the theme of course uses css... Thanks. |
You mean preventing the user from zooming in/out your page? If that is case then I guess there's no way to do it, the zoom is a user-controlled feature of the browser, we can't manipulate it via CSS or JavaScript.
You can, however, create a JavaScript system that increases/decreases font size on the fly. Take a look here for an example, you're gonna see 4 letter A's, clicking them will change the font-size of the article. I don't know Wordpress but there's probably a plugin out there to add this feature. |
thanks.
This feature is used in phpbb3 also. What I want to do is make it zoom friendly. So when a user zooms it, it doesn't look so bad |
To make sites zoomable I think you would have to make everything use a percentage value for their size. e.g.
Code:
.blah{ |
Normally, you use EM or PT for font sizes. To make them not scroll, use PX.
If you want to code everything well, you want to make everything work at any size. All of my sites work on both super small screens and super large screens. Most of the time using a % is the best way to go, unless if you want a specific value, such as the width of an image. And while you are at it, try not to use div's at all. Scary thought, huh? |
Quote:
What should I use then? |
He means make your code schematically correct. So titles use h1, h2, etc. Paragraphs use p. Don't throw everything in a div with a class or whatever.
|
of course I don't put everything in a div directly.
|
I was actually being sarcastic. It was more of a challenge than anything; try to make a working web page without using a single div.
Semantically correct code is the next best thing though ;) |
Quote:
In contrast, I think we all know not to use: HTML Code:
<div class="article_wrapper"> |
Divs used correctly name elements. So their intended purpose is to provide a block level <span>. such as below:
HTML Code:
<div id="HomeFooter">Id is used for elements that are used once in the page; logoStrip, leftColumnContent, footerLinks, ect. are all things that need ID's. Classes are for elements that are used more than once, so on this forum each post can have its own css class. [/rant] My post above was just saying that coding semantically correct is hard for some people. the code block you illustrated proves it. IPB Board uses too many Div's as well. Coding without <div>'s, however, looks like an impossible feat to many people. I just made a fun little navigation with that is just a list and a LOT of css :/. I even had to take a shortcut and put <br /> tags before the link text to move it down. mew mew if anyone can help me out on the navigation to remove the break tags I would be grateful. And, Freenity, sorry for hijacking. edit: Read more: The global structure of an HTML document |
Quote:
HTML Code:
<!-- *far* more concise than your html -->Quote:
The fact that browsers display a DIV at a block level is merely convention (it makes sense) but a DIV can quite happily be used inline or floated and still have good semantic value -- the DIV is dividing up the document, regardless of how the document is presented. A SPAN is something entirely different, and its meaning is easy to understand; just read the tag literally and you've got it. |
Quote:
The way that you phrased it is right, but <div>s displaying at block level isn't just convention. |
| All times are GMT. The time now is 04:32 PM. |
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0