Tag unknown s: property

I am new to Java / Struts 2. I am coding in Eclipse. I have two lines in my code with a warning sign.

These warnings:

unknown tag (s: property).

Below are two lines of code:

username : <s:property value="username" /><br/>
password : <s:property value="password" /><br/>


I don’t understand what happened. Is there anyone who can explain to me what the problem might be?


source to share

2 answers

The Eclipse JSP editor inspects the JSP files and if it finds errors in the code, red marks appear. You can also find errors in the problem presentation. Tags are validated against the TLD file, which must be declared using the JSP taglib directive. To use Struts tags in your code, you must place the code below at the top of the page

<%@ taglib prefix="s" uri="/struts-tags" %> 


Learn more about JSP Tags .

JSP TLD is included in struts2-core-xxxxjar.



ok I am using the directive

<%@ taglib prefix="s" uri="struts-tags"%> 


An error has occurred

correct directive below

<%@ taglib prefix="s" uri="/struts-tags"%> 


It was before my eyes ... :-(



All Articles