“Start tag head seen but an element of the same type was already open”, but I don’t have a duplicate <head>

后端 未结 1 1225
清酒与你
清酒与你 2021-01-28 12:33

I am validating my web page code in the W3Schools and it keeps giving me this error message:

Error: Start tag head seen but an element of the

1条回答
  •  迷失自我
    2021-01-28 12:59

    In your third line you have a before your start tag. Having a meta element after the start tag automatically opens the head element before the meta element, which causes your explicit tag to be detected as a duplicate.

    Simply move your underneath the tag to resolve this error:

    
    
    
    
    
    
     Index 
    
    

    (You can also remove the tag entirely and it would validate, too, but having a end tag without its start tag looks funny, even if the start tag isn't strictly necessary.)

    0 讨论(0)
提交回复
热议问题