Developing Web Applications with ASP.NET and Web Standards

Milan Negovan

AspNetResources.com

The End Game

ASP.NET is a very powerful platform for building the Web.

No matter how complicated back-end logic is, a Web Form ultimately produces HTML.

The $1M Question

Do we pay enough attention to the quality of HTML we send back to the user?

We can do better!

"Tag Soup" of Latter Days

Over the years it has become a habit to mix presentational and structural markup thus creating "tag soup" (familiar to developers as "spaghetti code")

How Did We End Up in This Mess?

What is Semantic (Structural) Markup?

se•man•tic
adj: Of or relating to meaning

The Web Standards Trinity

A suite of specifications developed by The World Wide Web Consortium (W3C)

The trinity of web standards

What is XHTML?

XHTML Ground Rules - Part I

XHTML Ground Rules - Part II

XHTML Ground Rules - Part III

Some elements and attributes have been deprecated

DOCTYPEs

There are three DTDs in XHTML 1.0

Validate

What is CSS?

Separation of Content and Presentation

One Stylesheet to Rule Them All

You can style the same code base in various types of media. "Build once, read everywhere."

Benefits: Development Savings

Benefits: Bandwidth Savings

Benefits: Accessibility & Wider Audience

Don't turn people down based on what they use to access your site or product

Benefits: Future Compatibility

Future compatibility with emerging user agents

Benefits: Be Ahead of the Game

Test in Multiple Browsers

Downsides

Mid-point Check

See if anyone in the audience is asleep and play "Ballmer sells Windows 1.0" to wake 'em up.

Case Study: Microsoft.com Home Page Redesign

Disclaimer: this was an unsolicited, unapproved exercise I undertook to demonstrate numerous benefits of developing with web standards. No animals were hurt in the course of this redesign.

  1. A Web Standards Showcase
  2. Genesis
  3. Rolling Up the Sleeves
  4. Pardon Our Dust
  5. The Final Frontier

Web Standards in ASP.NET 1.x

What is Adaptive Rendering?

Problems with Adaptive Rendering

ASP.NET 2.0: Huge step forward

VS.NET 2005: Huge step forward

ASP.NET 2.0: Control adapters

Allow you to tap into control rendering and tweak the ouput. Use them to produce markup of your choice.

Example: ASP.NET 2.0 CSS Friendly Control Adapters 1.0

Game Plan

Resources

Recommended reading

Resources

Recommended reading

Thank you. Come again.