SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Thread: .Net & DOCTYPE

  1. #1
    SitePoint Member
    Join Date
    Jul 2007
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    .Net & DOCTYPE

    First time, I'm going to design UI for a c#.net project. From Webpage design forum, it is advised to stick with HTML 4.01. But Visual Studio 2005, by default uses XHTML.

    Is there any specific reason to use XHTML in .NET? Since I don't know much about .NET, I have this query.

    Thanks, for any help, in advance.

  2. #2
    SitePoint Zealot
    Join Date
    Mar 2005
    Posts
    162
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yes, b/c XHTML makes logical sense.
    Web Application Development & Maintenance

  3. #3
    Chopped Liver bronze trophy imaginekitty's Avatar
    Join Date
    Aug 2007
    Location
    Pennsyltucky
    Posts
    1,494
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by eron19 View Post
    Yes, b/c XHTML makes logical sense.
    Can you please explain your position?

    XHTML is completely unnecessary unless you are using it to keep your documents well formed and validating* them and/or serving them as application/xhtml+xml. Sure you can use it as HTML and serve it as text/html but you are gaining nothing. It does simplify things a bit by disallowing certain deprecated tags and attributes, especially the presentational ones.

    A doctype serves only two purposes:
    • it switches the browser into standards mode
    • it give the validator a set of rules to validate against.
    Stick with HTML 4.01 Strict if that's what you're comfortable with.

    * All web pages should contain well formed and valid code. XHTML is just more strict (or should be) on the issue. You can write HTML 4.01 to XHTML standards keeping in mind the differences.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •