html-syntax

Discussion in 'HTML' started by Rune Runnestø, May 2, 2005.

  1. This code seems to work quite OK:
    <HTML><HEAD><TITLE></TITLE></HEAD><BODY>
    <FORM ACTION=goodLogin.jsp METHOD=POST>
    <BR>User Name:<INPUT TYPE=TEXT NAME=username>
    <BR>Password: <INPUT TYPE=TEXT NAME=password>
    <BR><INPUT TYPE=SUBMIT VALUE=Submit>
    </FORM>
    </BODY></HTML>

    but I thought it should be written like this:
    <HTML><HEAD><TITLE></TITLE></HEAD><BODY>
    <FORM ACTION="goodLogin.jsp" METHOD="POST">
    <BR>User Name:<INPUT TYPE="TEXT" NAME="username">
    <BR>Password: <INPUT TYPE="TEXT" NAME="password">
    <BR><INPUT TYPE="SUBMIT" VALUE="Submit">
    </FORM>
    </BODY></HTML>

    Is the one way with the "..." more recommended than the other way without ?

    Regards
    Rune
     
    Rune Runnestø, May 2, 2005
    #1
    1. Advertising

  2. Rune Runnestø

    Oli Filth Guest

    Rune Runnestø wrote:
    > This code seems to work quite OK:
    > <HTML><HEAD><TITLE></TITLE></HEAD><BODY>
    > <FORM ACTION=goodLogin.jsp METHOD=POST>
    > <BR>User Name:<INPUT TYPE=TEXT NAME=username>
    > <BR>Password: <INPUT TYPE=TEXT NAME=password>
    > <BR><INPUT TYPE=SUBMIT VALUE=Submit>
    > </FORM>
    > </BODY></HTML>
    >
    > but I thought it should be written like this:
    > <HTML><HEAD><TITLE></TITLE></HEAD><BODY>
    > <FORM ACTION="goodLogin.jsp" METHOD="POST">
    > <BR>User Name:<INPUT TYPE="TEXT" NAME="username">
    > <BR>Password: <INPUT TYPE="TEXT" NAME="password">
    > <BR><INPUT TYPE="SUBMIT" VALUE="Submit">
    > </FORM>
    > </BODY></HTML>
    >
    > Is the one way with the "..." more recommended than the other way without ?
    >


    http://www.w3.org/TR/html4/intro/sgmltut.html#h-3.2.2


    --
    Oli
     
    Oli Filth, May 2, 2005
    #2
    1. Advertising

  3. Rune Runnestø

    Andy Dingley Guest

    On Mon, 2 May 2005 15:48:18 +0200, "Rune Runnestø" <>
    wrote:

    >Is the one way with the "..." more recommended than the other way without ?


    Yes.

    You don't always need the quotes. But it's never bad to use them, and
    sometimes you _must_ use them (depending on the content inside them).
    For XML or XHTML work, they're always needed, so putting them in is a
    good habit to get into anyway.

    I suggest you take a read of the W3C website and the original HTML
    specifications.
     
    Andy Dingley, May 2, 2005
    #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. gabriele renzi
    Replies:
    2
    Views:
    221
    gabriele renzi
    Dec 31, 2005
  2. Ken Bloom
    Replies:
    3
    Views:
    224
  3. Good Night Moon
    Replies:
    9
    Views:
    292
    Rick DeNatale
    Jul 25, 2007
  4. Jacob Grover
    Replies:
    5
    Views:
    326
    Jacob Grover
    Jul 18, 2008
  5. Mark Richards
    Replies:
    3
    Views:
    324
    Tad McClellan
    Nov 18, 2007
Loading...

Share This Page