Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot

Re: Internet. Who should conform to who?

by AidanLee (Chaplain)
on Apr 26, 2002 at 13:23 UTC ( #162271=note: print w/replies, xml ) Need Help??

in reply to (OT) Internet. Who should conform to who?

There is a comprimise. But it may change the way you think about designing sites as well as coding them.

It is quite possible to use a subset of most of the "new" technologies that either:

  1. work in all browsers in some fashion or other
  2. fail gracefully -- meaning the site can get by with not having the browser be able to render a given technology

It is first important to note that "coding for the latest browsers" does not mean that you have to use 10 pages of javascript,css and the like. Honestly the first step to coding to modern standards won't affect older browsers' ability to render your page one iota. That is using XHTML (either 1.0 or 1.1). You can go so far as to use the strictest version of XHTML, and the older browsers will still render it fine. This would be an example of the first point above: a technology that works in all browsers.

A second example of number one is a technology that works "in some fashion or other" in all browsers. I will caveat and mention that I mean all 4.* and higher browsers, but I can explain how it will do no damage to earlier browsers that do not support it. What I am referring to is a subset of CSS. All 4th gen and higher browsers support some subset of CSS -- wether they agree on how to render it is another matter. But this brings me to my next point.

If you're coding for a large audience that uses such a wide variety of browsers, you should stop caring if your site looks 100% the same in every browser. It won't happen. Not in any practical way. And trying for 100% similarity becomes a maintinence nightmare. If one small change needs to be made to a page, you then have to re-check in every browser -- and probably make small changes for every browser's sake.

So if you take the plunge and commit to the philosophy that it's "ok" to have your sites look a bit different from browser to browser, there are a couple steps you can take to make your transition a success:

  • Structure your documents well. Use a header tag ( <h3> for example) to mean "this is a header," not to mean "this is a bit of large, bold text." Use paragraph tags to say "I want a paragraph here" not "I want more space between these lines than a line break will give me." Most importantly, use tables to mean "here's some tabular data" not "ooh, here's my page layout tool."
  • If you decide to try CSS positioning for the browsers that can handle it (I can hear cries from certain monks to turn away from the dark side), make sure you order your block elements in such a way as they still make logical sense if you were to read them on-screen in the same order as they're listed in the file. I actually like using lynx to check on this.
  • Do your homework. Be aware of what does and doesn't work for different browsers. Acquiring this knowledge will keep you from experiencing suprises, and will probably speed up your productivity. There are quite a few good sites that give easier to understand explanations of those wonderful w3c standards. I also find Westciv's CSS guide to be invaluable.

I'm sure everyone will weigh in on the subject of javascript, but I'll just throw in my opinion on the matter. If you use javascript, make it so it is a convenience to those who have it, but not an inconvenience to those who don't. The subset of compatible javascript between browsers is so small that in 98% of situations where you could use javascript, you probably shouldn't. And there is never a place where you can't get by without it.

So you can code to modern web standards without throwing out older browsers. You may not get to use all the toys in your toolbox, but it does not mean that you need to wallow in 5000 nested tables.

  • Comment on Re: Internet. Who should conform to who?

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://162271]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (4)
As of 2020-10-19 21:44 GMT
Find Nodes?
    Voting Booth?
    My favourite web site is:

    Results (207 votes). Check out past polls.