“未知标签(主)”在Eclipse中的JSP文件中发出警告 [英] "Unknown tag (main)" warning in JSP file in Eclipse

查看:165
本文介绍了“未知标签(主)”在Eclipse中的JSP文件中发出警告的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


$ b $

我有一个令人讨厌的行为与Eclipse,它告诉我关于我的JSP文件中的< main> 元素。 b

我的页面顶部有<!DOCTYPE html> ,我正在使用其他几个HTML5元素,例如< header> < footer> ,但Eclipse不会对此发出警告。



我尝试关闭HTML和JSP语法验证,但似乎不起作用。



我只是不明白为什么它有< main> 标签的问题,而不是其他HTML5标签,那么一点黄色的下划线是超级刺激的。



如何让Eclipse忽略这个标签?



提前谢谢你的答案。

解决方案

似乎人们根据评论@safin chacko中链接的问题,与HTML5属性有类似的问题。



在这里发布的答案显示了如何让Eclipse忽略指定的属性的验证。从那以后,似乎Eclipse具有能够忽略指定的元素的验证的附加功能



我已经发布了关于该问题的答案,这也回答了我自己的问题。


I have this annoying behaviour with Eclipse where it warns me about the <main> element in my JSP file.

I've got <!DOCTYPE html> at the top of my page and I'm using several other HTML5 elements, such as <header> and <footer>, but Eclipse doesn't give a warning about these.

I tried switching off HTML and JSP syntax validation but that didn't seem to work.

I just don't understand why it has a problem with the <main> tag but not other HTML5 tags and that little yellow underline is SUPER irritating.

How can I get Eclipse to ignore this tag?

Thank you in advance for your answers.

解决方案

So, it seems like people were having a similar problem with HTML5 attributes according to the question linked in the comment @safin chacko.

The answers posted there show how you could get Eclipse to ignore validation of specified attributes. Since then it seems that Eclipse has the added feature of being able to also ignore validation of specified elements

I have posted an answer on that question which also answers my own question.

这篇关于“未知标签(主)”在Eclipse中的JSP文件中发出警告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆