Html 菜单栏出现W3验证错误

Html 菜单栏出现W3验证错误,html,validation,dreamweaver,Html,Validation,Dreamweaver,在我的网站goblinnightvision.com上,我发现了几个我不理解的w3验证错误。我希望你们中的一些专家能给我一些帮助。下面我列出了我得到的一些验证错误: 第60行第13列:单据类型此处不允许有“br”元素;假设缺少“li”开始标记 第63行第32列:文档类型此处不允许元素“li”;缺少“ul”、“ol”、“menu”、“dir”开始标记之一 差不多 第66行第12列:省略了“li”的结束标记,但指定了省略标记号 第60行第8列:开始标记在这里 问候 杰夫 当然,如果没有我现在复

在我的网站goblinnightvision.com上,我发现了几个我不理解的w3验证错误。我希望你们中的一些专家能给我一些帮助。下面我列出了我得到的一些验证错误:

第60行第13列:单据类型此处不允许有“br”元素;假设缺少“li”开始标记

第63行第32列:文档类型此处不允许元素“li”;缺少“ul”、“ol”、“menu”、“dir”开始标记之一
  • 差不多

    第66行第12列:省略了“li”的结束标记,但指定了省略标记号

    第60行第8列:开始标记在这里

    问候 杰夫

    当然,如果没有我现在复制到这条消息中的代码,你不能说太多。我希望从中你能告诉我我做错了什么

    亲爱的马克斯:

    谢谢你在这方面的帮助。关于这些错误,我复制了菜单栏的一部分,也许这对你来说是有意义的,因为它对我来说仍然没有意义。我当然是这方面的新手;-)





    让我们从这个开始:

    Line 63, Column 32: document type does not allow element "li"
    here; missing one of "ul", "ol", "menu", "dir" start-tag. 
    
    这基本上是说,如果没有
    标记,就不能有
  • (您需要指定它是什么类型的列表)

    这意味着您有一个结束标记,但没有开始标记

    Line 60, Column 13: document type does not allow element "br" here; 
    assuming missing "li" start-tag
    
    我不完全确定这一点,但我认为这是在说,您不应该在
  • 元素中放置

    ,因为
  • 项无论如何都在单独的行中

    Line 60, Column 8: start tag was here
    
    这一个,我没有线索,如果没有代码来配合它


    希望这有帮助

    我又一次偶然发现了这个链接,我不太确定你是否已经弄明白了,但我们开始吧。我认为我个人拥有我认为你需要的东西,所以我将分享我的东西。我还假设您需要一个下拉菜单,它只能通过一些CSS获得,我将提供给您

    HTML:


    1.在没有看到代码的情况下,您希望我们如何帮助您?2.错误消息告诉您需要知道的一切。
    Line 60, Column 13: document type does not allow element "br" here; 
    assuming missing "li" start-tag
    
    Line 60, Column 8: start tag was here
    
     <div id="dropnav">
              <ul class="navbar">
                 <li><a href="/index.html">Home</a></li>
                 <li><a href="#.html">#</a>
                    <ul>
                       <li><a href="#.html">#</a></li>
                       <li><a href="#.html">#</a></li>
    
                    </ul>         
                 </li>
                 <li><a href="#.html">#</a>
                    <ul>
                       <li><a href="#.html" >#</a></li>
                        <li><a href="#.html" >#</a></li>
    
                    </ul>         
                 </li>
                 <li><a href="#.html">#</a>
                    <ul>
                       <li><a href="#.html">#</a></li>
    
                    </ul>         
                 </li>
                 <li><a href="#.html">#</a>
                    <ul>
                       <li><a href="#.html">#</a></li>
    
                    </ul>         
                 </li>
                 <li><a href="#.html">#</a>
                    <ul>
                       <li><a href="#.html">#</a></li>
                       <li><a href="#.html">#</a></li>
    
                    </ul>  
    
              </ul>
    </div>
    
    #dropnav    {
        width: 100%; /* Spans the width of the page */
        height: 50px; 
        padding-bottom: 10px;
        margin: 0; /* Ensures there is no space between sides of the screen and the menu */
        z-index: 1; /* Makes sure that your menu remains on top of other page elements */
        position: relative;
        background-color: rgba(0, 0, 0, 0.00);
        }
    .navbar {
        height: 50px;
            padding: 0;
            padding-bottom: 10px;
        margin: 0;
        position: absolute; /* Ensures that the menu doesn’t affect other elements */
        border-right: 1px solid #54879d; 
        }
    .navbar li  {
        padding-bottom: 10px;
                height: auto;
                width: 150px;  /* Each menu item is 150px wide */
                float: left;  /* This lines up the menu items horizontally */
                object-position: top;
                text-align: center;  /* All text is placed in the center of the box */
                list-style: none;  /* Removes the default styling (bullets) for the list */
                font: normal bold 12px/1.2em Arial, Verdana, Helvetica;  
                padding: 0;
                margin: 0;
                background-color: rgba(0, 0, 0, 0.00);
                            }
    .navbar a   {                           
            padding: 18px 0;  /* Adds a padding on the top and bottom so the text appears centered vertically */
            border-left: 1px solid #000; /* Creates a border in a slightly lighter shade of blue than the background.  Combined with the right border, this creates a nice effect. */
            border-right: 1px solid #000; /* Creates a border in a slightly darker shade of blue than the background.  Combined with the left border, this creates a nice effect. */
            text-decoration: none;  /* Removes the default hyperlink styling. */
            color: white; /* Text color is white */
            display: block;
            }
    
    .navbar li:hover, a:hover {
        background-color: rgba(0, 0, 0, 0.00);
    }
    
    .navbar li ul   {
            display: none;  /* Hides the drop-down menu */
            height: auto;                                   
            margin: 0; /* Aligns drop-down box underneath the menu item */
            padding: 0; /* Aligns drop-down box underneath the menu item */         
            }               
    
    .navbar li:hover ul     {
                            display: block; /* Displays the drop-down box when the menu item is hovered over */
                            }
    
    .navbar li ul li {
        background-color: #808080;
    }
    
    .navbar li ul li a  {
            border-left: 1px solid #808080;
            border-right: 1px solid #808080;
            border-top: 1px solid #808080;
            border-bottom: 1px solid #808080;
            }
    
    .navbar li ul li a:hover {
        background-color: #9a9a9a;
    }