Monday, May 4, 2009

Web 2.0: no more tables?

What is "web 2.0" or where are the specs? Is is just by applying and using AJAX?


I read many comments saying that "tables" are "old fashion". What is to replace them? "Div" ?


I develop a lot with AJAX, Divs and tables, but I believe that a table, using % instead of width, are better for any screen resolution.


Advices ? Comments ?

Web 2.0: no more tables?
Tables are still available. Web 2 just has more powerful inbuilt features, but is still capable of handling previous features.
Reply:I believe tables are used less nowadays because of accessibility issues with screen readers. Check here for guidelines.





I heard it's good to use DIV with absolute positioning. This way, you could dynamically change the displays via different stylesheets.





www.w3c.org/tr/wai-webcontent
Reply:You can style div layouts with percentage as well. There has been no reason to use tables as presentation devices since 1999, when CSS became widely supported. Tables as presentation devices are an old-fashioned error in any design.


In any event, they fail to follow modern standards, which separate style from structure.


The table tag continues to be supported in drafts as a container for *tabular data* only. Ie., charts and other dimensionally related visual databases. Not as stylistic devices.


If you cannot get your CSS to resize properly, have a look at the many working CSS layouts freely available on the web and what makes them work.
Reply:The life of the %26lt;table%26gt; tag is not really related to web 2.0. Tables will still exist for tabular data ... but they have tended to be used for layout which is where they will eventually decrease in popularity.





Typically, and for lots of pertinent reasons, developers now separate styling from content, using %26lt;div%26gt; tags and floats etc etc which means your content can be properly ordered and your website is accessible to various users and with various browsers.





The biggest fly in the ointment is that a large percentage of people still use non standards compliant browsers (IE) which means there are a bunch of hacks you need to get to grips with, but that is probably easier to learn than the java script and table alternative you suggested.





Hope that helps





Karen








*** Added ***





Thanks for the comment Just JR, but sticking to the most popular (Internet Explorer) is where you see the problems. IE IS an non standard compliant browser and it IS the one you have to build hacks into your CSS for ... it is just something to be mindful of when you are using CSS for styling.


No comments:

Post a Comment