First: First try to add struts2 DTD constraints, and some will be added after the save to reopen the code hints.
The concrete steps are as follows: Take struts2-2.3.16 as an example
1. Click Window,preferences,xml Catalog;
2. In the popup dialog box, select the first user, click Add;
3.location for your struts2 src below the core in sequence Src,main,resource, finally select the corresponding STRUTS2 version of the DTD constraint package, my 2.3.16DTD configuration is as follows: D:\Java\ Struts-2.3.16.3\src\core\src\main\resources\struts-2.3.dtd
4. Select the key type as the URL, my key is: HTTP://STRUTS.APACHE.ORG/DTDS/STRUTS-2.3.DTD, the corresponding version of the STRUTS2 to modify
5. Always ok after saving, re-open there may be XML code hints.
If none of the above is the second case:
Second: Many people do not have a hint after the first one, this may be your myeclipse setup problem.
MyEclipse will use the Struts configuration Editor to edit the Struts.xml file by default, and this editor is a bug, so it's better to change to an XML editor.
The steps are as follows:
Window->preferences->general->editors, click on the ' File associations ' link above
Find "*.xml" in the box above, select "MyEclipse XML Editor" in the box below and click "Default Button", then click "OK".
After this setting you will find that your struts.xml becomes the style opened in XML Editor, and when you reopen it, input < will automatically have code hints.