SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Enthusiast
    Join Date
    Dec 2007
    Posts
    66
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Angry Validator Problems

    Hi I have being having problems with validator and I was wondering if anyone could tell me why its say its not a valid doctype.

    Help will be appreicated as always.

    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta name="generator" content="HTML Tidy for Linux (vers 1 September 2005), see www.w3.org" />
    <link href="admin.css" rel="stylesheet" type="text/css" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Untitled Document</title>

    <style type="text/css">
    /*<![CDATA[*/
    div.c1 {text-align: left}
    /*]]>*/
    </style>
    </head>
    <body>
    <div id="container">
    <div id="banner"><img src="Logo.gif" alt="Logo" width="770" height="150" /></div>
    <div id="navbar"></div>
    <div id="sidebar">
    <p><img src="candidatesearch.gif" alt="candidate search" name="CanS1" width="100" height="100" hspace="60" vspace="11" border="0" id="CanS1" /></p>
    <form id="form1" name="form1" method="post" action=""><label>VacancyLocation <select name="VacancyLocation" id="VacancyLocation">
    <option>UK</option>
    <option>USA</option>
    <option>Germany</option>
    <option>France</option>
    <option>Italy</option>
    </select></label> <label><br />
    Can work in UK <select name="Authorised to work in the UK" size="1" id="AuthorisedtoworkintheUK">
    <option selected="selected">Yes</option>
    <option>No</option>
    </select></label></form>
    <form id="form2" name="form2" method="post" action="">
    <p> </p>
    </form>
    </div>
    <div id="uppernav"><img src="JobMatcher.gif" alt="Job Matcher" width="75" height="75" />
    <form id="form3" name="form3" method="post" action="">
    <div class="c1"><label>Employer Name <input type="text" name="Employer Name" id="Employer Name" accesskey="ALT" /><br />
    Location <input type="text" name="Location" id="Location" accesskey="ALT" /> Title <input type="text" name="Title" id="Title" accesskey="ALT" /><br />
    Positions <select name="Positions" size="1" id="Positions">
    <option>1</option>
    <option>2</option>
    <option>3</option>
    <option>4</option>
    <option>5+</option>
    </select> Description <input name="Description" type="text" id="Description" accesskey="ALT" value="" size="45" /><br />
    <input type="submit" name="Match" id="Match" value="Match" accesskey="ALT" /><br /></label></div>
    </form>
    </div>
    </div>
    </body>
    </html>

  2. #2
    He's No Good To Me Dead silver trophybronze trophy stymiee's Avatar
    Join Date
    Feb 2003
    Location
    Slave I
    Posts
    23,426
    Mentioned
    2 Post(s)
    Tagged
    1 Thread(s)
    Because it is missing completely. See http://www.alistapart.com/articles/doctype/ to see what a correct doctype looks like.

  3. #3
    SitePoint Enthusiast Mongoose.wa's Avatar
    Join Date
    Feb 2008
    Location
    Seattle, WA
    Posts
    68
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    For future reference, please link us to the validator page, please.

    It's saying you're not using a valid doctype because you're not using a doctype at all. You have to specify what type of markup you're using, in the form of a doctype declaration. You'll want either XHTML strict or transitional.

  4. #4
    In memoriam gold trophysilver trophybronze trophy Dan Schulz's Avatar
    Join Date
    May 2006
    Location
    Aurora, Illinois
    Posts
    15,478
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You'll also be better off placing your stylesheet in an external file and linking to it from the Web page via the LINK element.

  5. #5
    SitePoint Enthusiast
    Join Date
    Dec 2007
    Posts
    66
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Have copied tp the CSS forum aswell

    Thanks guys it says its valid

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta name="generator" content="HTML Tidy for Linux (vers 1 September 2005), see www.w3.org" />
    <link href="admin.css" rel="stylesheet" type="text/css" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Untitled Document</title>

    <style type="text/css">
    /*<![CDATA[*/
    div.c1 {text-align: left}
    /*]]>*/
    </style>
    </head>
    <body>
    <div id="container">
    <div id="banner"><img src="Logo.gif" alt="Logo" width="770" height="150" /></div>
    <div id="navbar"></div>
    <div id="sidebar">
    <p><img src="candidatesearch.gif" alt="candidate search" name="CanS1" width="100" height="100" hspace="60" vspace="11" border="0" id="CanS1" /></p>
    <form id="form1" name="form1" method="post" action=""><label>VacancyLocation <select name="VacancyLocation" id="VacancyLocation">
    <option>UK</option>
    <option>USA</option>
    <option>Germany</option>
    <option>France</option>
    <option>Italy</option>
    </select></label> <label><br />
    Can work in UK <select name="Authorised to work in the UK" size="1" id="AuthorisedtoworkintheUK">
    <option selected="selected">Yes</option>
    <option>No</option>
    </select></label></form>
    <form id="form2" name="form2" method="post" action=""></form>
    </div>
    <div id="uppernav"><img src="JobMatcher.gif" alt="Job Matcher" width="75" height="75" />
    <form id="form3" name="form3" method="post" action="">
    <div class="c1"><label>Employer Name <input type="text" name="EmployerName" id="EmployerName" accesskey="ALT" /><br />
    Location <input type="text" name="Location" id="Location" accesskey="ALT" /> Title <input type="text" name="Title" id="Title" accesskey="ALT" /><br />
    Positions <select name="Positions" size="1" id="Positions">
    <option>1</option>
    <option>2</option>
    <option>3</option>
    <option>4</option>
    <option>5+</option>
    </select> Description <input name="Description" type="text" id="Description" accesskey="ALT" value="" size="45" /><br />
    <input type="submit" name="Match" id="Match" value="Match" accesskey="ALT" /><br /></label></div>
    </form>
    </div>
    </div>
    </body>
    </html>

    and css is valid to

    @charset "utf-8";
    #container {
    position : relative;
    margin : 0 auto;
    width : 770px;
    height : 770px;"was 500px before altering"
    background-color : #cccccc;
    }
    #banner {
    position : relative;
    left : 0;
    top : 0;
    width : 770px;
    height : 150px;
    background-color : #ffffff;
    }
    #navbar {
    position : relative;
    left : 0;
    top : 0;
    width : 770px;
    height : 50px;
    background-color : #000000;
    }
    #sidebar {
    position : relative;
    left : 0;
    top : 0;
    width : 250px;
    height : 300px;
    background-color : #ffffff;
    border : 1px inset #00008b;
    }
    #uppernav {
    position : relative;
    left : 300px;
    top : -301px;
    width : 470px;
    height : 250px;
    background-color : #ffffff;
    }

    Is there a better of positioning my uppernav div as when I coded it I seemed to get a lot of white space in the container when I altered the postion using dreamweaver.

    Greatful for anymore help thanks


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
  •