Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 14 of 14
  1. #1
    New to the CF scene
    Join Date
    Dec 2012
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Help Validating XHTML Strict 1.0

    Need some help validating this,can't seem to find the error at all...

    Its for college btw.

    Error taken from W3 Schools XHTML Validator
    Error Line 99, Column 7: end tag for "div" omitted, but OMITTAG NO was specified

    </body>


    You may have neglected to close an element, or perhaps you meant to "self-close" an element, that is, ending it with "/>" instead of ">".


    Code:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    
         <head>
             <title>BF3</title>
    		<link rel="stylesheet" type="text/css" href="Project.css"/>
         </head>
    
    
    <body>
    
    
     <div id="page">
    <img src="Fields_wallpapers_411.jpg"alt="Top Part" height="300" width="1000"/>
     <div id="nav_bar">
        <ul>
            <li><a href="index.html">Home       </a></li>
            <li><a href="tickets.html">Weapons  </a></li>
            <li><a href="members.html" class="Classes">
                Maps</a></li>
            <li><a href="about_us.html">Vehicles</a></li>
            <li><a href="about_us.html">Factions</a></li>
            <li><a href="about_us.html">Tips &amp; Tricks</a></li>
        </ul>
    </div>
    
    
    <div id="homepage">
    
    
    <div id="title"><h2>Welcome to my Battlefield 3 site.</h2></div>
    <p>Battlefield 3 (commonly abbreviated BF3) is a first-person shooter video game developed by EA Digital Illusions CE and published by Electronic Arts.
    It is a direct sequel to 2005's Battlefield 2, and the twelfth installment in the Battlefield franchise.
    
    
    The game was released in North America on 25 October 2011 and in Europe on 28 October 2011 for Microsoft Windows, PlayStation 3, and Xbox 360.
    EA Mobile also confirmed a port for the iOS platform. The game sold 5 million copies in its first week of releaseand received critical acclaim from most game reviewers.
    It is the first game in the series that does not support versions of Windows prior to Windows Vista as the game only supports DirectX 10 and 11.
    The PC version is exclusive to EA's Origin platform,through which PC users also authenticate when connecting to the game.
    
    In campaign mode, players take on the personas of several military roles; a Force Recon Marine, an F/A-18 weapons system officer,
    an M1A2 Abrams tank operator, and a GRU Spetsnaz operative. The campaign takes place at various locations, from Iran to New York,
     and follows the story of Sergeant Henry Blackburn and later, Dimitri Mayakovsky. </p>
    
    
    
    
    <h2> Campaign </h2>
    <p>The game's campaign takes place in the year 2014. The missions are flashbacks that are part of the interrogation of Staff Sergeant Blackburn and do not occur in order of events.
    Chronologically, the initial sections of the campaign are set near the Iraq-Iran border, where the US Marine Corps are fighting the People's Liberation and Resistance (PLR).
    The game later moves into northern Iran, continuing the fight against the PLR. There is a mission set in the streets of Paris, and another set in the sewers and subways of New York.</p>
    
    
    <div id="review">
    
      <h2> <a href="http://battlelog.battlefield.com/bf3/about/game/armored-kill/">Armored Kill OUT NOW</a></h2>
    
    
          <p><i>OnPS3,XBOX 360 & PC       </i></p>
    
    
    
             <img src="Armoud Kill.png"alt="Top Part"/>
     </div>
    
    
    <p>Click Below Image to Order Now<a href="http://battlelog.battlefield.com/bf3/premium/">
    <img src="Battlefield-3-Premium.jpg" alt="Preium" width="480" height="500"/></a></p>
    
    
    
    
    
    
    <h2>Downloadable Content</h2>
     <ol>
        <li><i>Back To Karkand   </i></li>
        <li><i>Close Quaters     </i></li>
        <li><i>Amored Kill       </i></li>
        <li><i>Aftermath         </i></li>
        <li><i>Endgame           </i></li>
     </ol>
    
    
    
    
    <img src="bf3_small_feature_promo_usp1.jpg"alt="Top Part" height="300" width="350"/>
    
      <img src="bf3_small_feature_promo_usp2.jpg"alt="Top Part" height="300" width="280"/>
    
         <img src="bf3_small_feature_promo_usp3-2.jpg"alt="Top Part" height="300" width="360"/>
    
    
    </div>
    
    
    
    </body>
    
    </html>

  • #2
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,461
    Thanks
    1
    Thanked 23 Times in 21 Posts
    We have a policy of not doing other people's homework, but we do offer hints.

    Usually when I have a well-formedness problem like this that I can't solve, I make a copy of the document in question. Then I take the copy and start removing sections that I know are good. Eventually, I'll isolate where I went wrong. This is a technique that works really well in any scripting language, too.

    Another option is to use an editor that supports either code folding or syntax highlighting. Komodo Edit does both, and it's free: I've used it for years. I suspect that with code folding, you'll find the error within minutes.
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog

  • #3
    New to the CF scene
    Join Date
    Dec 2012
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Ok thanks can you suggest and editor? Seeing as its only one error can you give me a BIG Clue,need to get this validated today

  • #4
    Senior Coder
    Join Date
    Aug 2006
    Posts
    1,341
    Thanks
    11
    Thanked 288 Times in 287 Posts
    It's telling you that you have opened a <div> but have not closed it with a corresponding </div>. You could count the <div> elements and see there is one less </div>. Just pair them up and decide where you forgot a <div>. You could also put a comment (like <!-- end of "page" div -->) at each of the </div> and it might make it easier to spot a missing one.

    Dave

  • #5
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,461
    Thanks
    1
    Thanked 23 Times in 21 Posts
    Quote Originally Posted by Yedya View Post
    Ok thanks can you suggest and editor? Seeing as its only one error can you give me a BIG Clue,need to get this validated today
    I already did, Komodo Edit: http://www.activestate.com/komodo-edit/downloads

    P.S. When I tried your document in Komodo, it wasn't just one error... that's how XML works: at the first well-formedness error, it stops processing.

    P.P.S. Try http://validator.w3.org/#validate_by_upload for validation. :-)
    Last edited by Alex Vincent; 12-14-2012 at 06:17 PM.
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog

  • #6
    New to the CF scene
    Join Date
    Dec 2012
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thank you! Fixed the error and now the validator is throwing out more errors
    Line 62, Column 35: Couldn't find end of Start Tag img line 62
    <img src="Armoud Kill.png"alt="Top Part"/>
    6 of these? and i honestly don't see where its wrong in the code...

  • #7
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,461
    Thanks
    1
    Thanked 23 Times in 21 Posts
    Code:
    <img src="Armoud Kill.png"alt="Top Part"/>
    What's wrong here?
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog

  • #8
    New to the CF scene
    Join Date
    Dec 2012
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by Alex Vincent View Post
    Code:
    <img src="Armoud Kill.png"alt="Top Part"/>
    What's wrong here?
    Nothing according to this


    Code:
    <img border="0" src="/images/pulpit.jpg" alt="Pulpit rock" width="304" height="228">
    taking from


    http://www.w3schools.com/html/tryit....ml_pulpitimage


    I actually am so stressed now

  • #9
    New to the CF scene
    Join Date
    Dec 2012
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Not seeing any error this is so stressful


    I checked on w3 shools and according to that site thats thew way your meant to link images.

  • #10
    Senior Coder
    Join Date
    Aug 2006
    Posts
    1,341
    Thanks
    11
    Thanked 288 Times in 287 Posts
    Let'ssee,howdoIputthismoreclearly.Stepbackandlookatthecodeasfarasitneedstobeparsedintoindividualtags ,attributesandstrings...Dave

  • #11
    New to the CF scene
    Join Date
    Dec 2012
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by tracknut View Post
    Let'ssee,howdoIputthismoreclearly.Stepbackandlookatthecodeasfarasitneedstobeparsedintoindividualtags ,attributesandstrings...Dave
    So it needs to be parsed into individual tags? I have no idea how to do that..
    Im not asking for alot,just a few simeple errors...im new to programming



    Guess il go google it.

  • #12
    Senior Coder
    Join Date
    Aug 2006
    Posts
    1,341
    Thanks
    11
    Thanked 288 Times in 287 Posts
    Sorry, I thought that would have given you the tip. Tags and attributes in html are separated by white space (spaces, tabs, returns) so that your browser knows where they start and end. The formatting of html is rather loose, but you do need to adhere to a few common rules like that. That line of code is missing white space between the string and the following attribute.

    Dave

  • #13
    New to the CF scene
    Join Date
    Dec 2012
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Many thanks man! Really appreciate it,its passed now

  • #14
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,461
    Thanks
    1
    Thanked 23 Times in 21 Posts
    So, what'd you learn from this? Don't just quote Dave - put it in your own words.

    (I'm in college myself - but I enjoy taking the role of a mentor from time to time.)
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog


  •  

    Posting Permissions

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