Skip to main content
maryanns50585047
Known Participant
February 7, 2017
Answered

Unclosed Element Div

  • February 7, 2017
  • 3 replies
  • 2682 views

This page can be viewed at http://www.maselva.com/Certification.html# Page displays properly on server but Dreamweaver does not validate.

Nancy has told me, "You MUST learn to comment ALL of your tags", so I am adding comments in order to close these elements.

Either I have done this incorrectly (no doubt) or something all together different is the problem.

I would appreciate any light you could shed on this.

MaryAnn in Texas

    This topic has been closed for replies.
    Correct answer osgood_

    The end of your page should look like below:

    </div>

    </div>
    <!-- end media-object-default -->
    </div>
    <!-- end col-lg-6 col-md-6 -->
    </div>
    <!-- end container -->

    </body>
    </html>

    But you have this:

    </div>

    <!-- end col-lg-6 col-md-6 -->

    <!-- end media-object-default -->
    <!-- end container -->

    </body>
    </html>

    3 replies

    osgood_Correct answer
    Legend
    February 7, 2017

    The end of your page should look like below:

    </div>

    </div>
    <!-- end media-object-default -->
    </div>
    <!-- end col-lg-6 col-md-6 -->
    </div>
    <!-- end container -->

    </body>
    </html>

    But you have this:

    </div>

    <!-- end col-lg-6 col-md-6 -->

    <!-- end media-object-default -->
    <!-- end container -->

    </body>
    </html>

    maryanns50585047
    Known Participant
    February 7, 2017

    Sorry about the blank email…trigger finger.

    The light bulb comes on!

    So I had correctly added the comments. I just must add close divs before comment!? Also I see the sequence of comments on mine was not correct.

    Legend
    February 7, 2017

    maryanns50585047 wrote:

    So I had correctly added the comments. I just must add close divs before comment!?

    Sure comments are just comments to help you identify where the container ends, The container still needs to be closed with a closing tag.

    maryanns50585047 wrote:

    Also I see the sequence of comments on mine was not correct.

    Your  'media-object-default' container sits inside your 'col-lg-6 col-md-6 'container so it needs to be closed first, so natuarlly the comment would come first.

    Nancy OShea
    Community Expert
    Community Expert
    February 7, 2017

    See screenshot.  Hopefully this will help you identify code errors while you work.  In the example below, I have 2 un-closed <div> tags from line 9 and line 8.

    Nancy

    Nancy O'Shea— Product User & Community Expert
    Nancy OShea
    Community Expert
    Community Expert
    February 7, 2017

    You have 3 un-closed <div> tags.  Try closing them with </div> and see how it looks.

    Nancy

    Nancy O'Shea— Product User & Community Expert