Hi,all
I design a tag, it's very common and it's a jsp tag, the code is like:
-------------------------------------------------------------------------------------------------------------------
public class NewsCommentTag extends TagSupport {

/**
*
*/
private static final long serialVersionUID = 2335725745314009551L;

@Override
public int doStartTag() throws JspException {
-------------------------------------------------------------------------------------------------------------------
Nothing special. Then I use it in jsp page like:
<newscomment:comment news="%{news.title}" category="%{news.category}">

</newscomment>

But I can not retrieve anything in my tag class using set and get methods.

Then I write: <s:property value="%{news.title}"></s:property>,
the page could print the correct result.

Can't I use OGNL expression in user-defined jsp tag? or there are other
roles?


I use struts2.0.12.

Thanks!

-- 

Thanks!

Mobile: +086-15864011231
Website:http://www.openmotel.cn
        http://www.vvthumb.com
GTalk:[EMAIL PROTECTED]
Skype:saharabear


Haulyn Runner Jason



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to