<doctype> vs namespace

Discussion in 'HTML' started by don, Apr 24, 2012.

  1. don

    don Guest

    If a <doctype> tells the browser what version of HTML is being used for the
    web site what is a namespace telling it? Why do we need both?
    don, Apr 24, 2012
    #1
    1. Advertising

  2. 2012-04-24 23:11, don wrote:

    > If a <doctype> tells the browser what version of HTML is being used


    It does not.

    > what is a namespace telling it?


    It's telling that tags are HTML tags and not FunML or BurpML ot HotSexML
    tags, to those user agents that care about such things.

    > Why do we need both?


    What makes you think you need either of them?

    --
    Yucca, http://www.cs.tut.fi/~jkorpela/
    Jukka K. Korpela, Apr 24, 2012
    #2
    1. Advertising

  3. 2012-04-25 14:06, Alan_Smith wrote:

    > <!DOCTYPE> is not the tag of the HTML but it is must to be mentioned
    > above the HTML tag because it is used to instruct the browser about
    > version of the HTML in which the page has been written


    Do you really think so? Did you *ever* test the idea?

    Try writing a document with all kinds of modern tags and slap an HTML
    2.0 doctype at the start. Do you think browsers will then refuse to
    recognize the modern tags? Did you really expect that to happen? What
    *do* you mean my “instruct the browser about version of the HTML†if not
    such things?

    > whereas
    > namespace is used conflict between element names to avoid.


    Exactly how would a namespace declaration be an HTML thing, given that
    there is a single HTML namespace?

    --
    Yucca, http://www.cs.tut.fi/~jkorpela/
    Jukka K. Korpela, Apr 25, 2012
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Èý¹â
    Replies:
    1
    Views:
    558
    William F. Robertson, Jr.
    Jul 29, 2003
  2. Replies:
    0
    Views:
    5,113
  3. Anonymous
    Replies:
    3
    Views:
    516
    Ron Natalie
    Aug 18, 2003
  4. Jason Heyes
    Replies:
    1
    Views:
    443
    Woebegone
    Nov 19, 2004
  5. Larry Lindstrom
    Replies:
    19
    Views:
    1,272
    Jonathan N. Little
    Jun 12, 2012
Loading...

Share This Page