Jump to content
xisto Community
the_furious1

Optimizing Website?

Recommended Posts

No I don't mean that.I mean when I use CSS and absolute positioning, my page shows different on Internet Explorer and FireFox (left positioning 0 in Internet Explorer is like -2 in FireFox). I wanted to now if there is a way for the page to show up the same way in both browsers.I was thinking something like this:For me to have to css files (one for FireFox and the other one for IE), and somehow for web site to recognize the browser and to load corresponding css file. Java script or something.I don't know JavaScript, so I don't know if that is possible!If that is possible can somebody show me how make it, or if somebody knows the easier way please tell me!

Share this post


Link to post
Share on other sites

you mean using same code for both. I dont believe you can...netscape engine supports some of the commands in css and such like but not all of them unfortaunately :).It would be better to make one page for netscape users and one page for IE users. hat would be trhe easier way.

Share this post


Link to post
Share on other sites

I dont think there any way to make that possible. If you look at my website, the pic at the top looks real nice with IE but when you look at it with FireFox or any of the Gecko browsers, there is a disallignment in the positioning and if i try to corect that, it doesnt look too well in IE and thats why I have left it that way for some time now.I think you can optimize it for one and take your channces in the others.

Share this post


Link to post
Share on other sites

You've hit the problem I, along with just about every other web designer, are finding... CSS is split into 3 categories, cunningly entitled CSS1, CSS2 and CSS3. (CSS3 is the newest). How the browser interprets the page depends on which of these it supports. Example: Internet Explorer only supports CSS1 officially. Meaning that it has trouble with some of the more advanced stuff in CSS2. Firefox and Gecko browsers now support CSS2 and parts of CSS3 (even though css3 isnt officially out yet so I guess we shouldn't count it). Theoretically then, if you had a browser that used only basic CSS then the page would look the same? Sadly not. Text sizes, screen res and generally what the browsers settings are affect your design. opera, for example, puts an 8px white space around every page! But then Opera is the wierdest and most illogical browser I've ever seen.Conclusion: No. Even if you validate it completely it's never going to look exactly the same, especially if you use more complx css. Annoying. This is the main reason why I prefer firefox over anything else. It renders things properly!

Share this post


Link to post
Share on other sites

You should optimize your site for IE users. Most of the people in Internet use IE so i will do optimize my code for IE. I prefer Firefox too but reality is reality.

Share this post


Link to post
Share on other sites

It is possible to optimize your website for both Internet Explorer and Firefox. You would have to spend more time though, because of different types of element rendering. When you really do it by the book, you will find out that it still looks different in Internet Explorer and Firefox. Then you will have to apply some workarounds, but it would still be valid css.

If you want to optimize your website it would be smart to change your html 4.0 to xhtml 1.1 and then try to apply css for markup. At http://www.cssvault.com/rg-erdr.php?_rpo=t you will find a list of categories of useful CSS resources. If you want to get started, take a look at the layout category. If you get stuck and need some useful hack, look no further!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.