Multiple annotations found at this line: - Invalid text string ( | ). - Invalid text strin

在Eclipse/Myeclipse下开发,jsp页面有时会报Multiple annotations found at this line错误

原因是:这些标签的位置,或者属性不符合html的规范,但并不影响这些标签正常表示

比如:

   <span><div></div></span>  

中间的div标签就会报下面这种错误

Multiple annotations found at this line:
- Invalid text string ( |   
  ).
- Invalid text string ( |   
  ).

原因是span属于内联元素,div属于块状元素

内联元素放在块状元素中,不符合html规定,所以就会报错


块状元素和内联元素介绍:
http://www.cnblogs.com/vidudu/articles/KwooJan.html

猜你喜欢

转载自blog.csdn.net/qq_38963960/article/details/79030476
今日推荐