Powering ASP.Net By CSS
When developing a web site one can choose between creating a CSS-based or TABLE-based web site. Both types of layouts have advantages and disadvantages and perform quite differently.
TABLE-based layouts web sites have the flowing facts:
- They're easy to use and implement (compared to CSS-layouts).
- WYSIWYG (What You See Is What You Get) editors like FrontPage and Dreamweaver make it very easy for developers to include them.
- Tables "break" on various browsers (newer and older versions) thus producing layout dysfunctions.
- Increase almost unnecessarily the HTML/text ratio. This means that other options could be used to create layouts that produce smaller page files by employing less HTML tags.
And
CSS-based layouts web sites have the flowing facts:
- Widely supported by modern browsers but not by older browsers
- Allows extreme flexibility in positioning
- Increases usability by encouraging liquid design
- Keeps the HTML/text ratio at a low level thus decreasing load time
- Allows the display of main content first while the graphics load afterwards
You can think now that CSS layout is more powerful than table based layout and Tables should only be used in extreme cases where there is no other viable alternative.
So if you need to improve your ASP.net Web Site performance and layout then you need to add CSS functionality to your site by using elements other than table if it possible like DIV, UI, LI … with CSS
But what I can do with ASP.Net server controls? You can use ASP.NET CSS Friendly Control Adapters 1.0 that provided more flexibility for customizing the rendered HTML. For example, the Menu control makes it simple to add a menu to a web site, but it would be better if it didn't create <table> tags and was easier to style using CSS. Happily, it's easy to customize and adapt the Menu control to generate better HTML. Indeed, you can modify any ASP.NET control so it produces exactly the HTML you want.
For more details:
ASP.NET 2.0 CSS Friendly Control Adapters 1.0
CSS Layouts Vs. Table Layouts - Alternate Browsers and Accessibility Issues