File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

problem with tag html:text value=...

 
Nirnay Rane
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am getting exception for the tag
<html:text property="NewTitle" value="<bean:write name="OtherBean" property="title"/>" ></html:text >

My JSP page similar as follows

---code------
<jsp:useBeanid="fillForm"
scope="request"
type="OtherBean" />

<html:form action="/DisplayGraphStep2">

Title : <html:text property="NewTitle" value="<bean:write name="OtherBean" property="title"/>" ></html:text >
</html:form>
---code------

This code doesn't work. gives an exception ..
org.apache.jasper.JasperException: /Step1.jsp(24,69) equal symbol expected

/DisplayGraphStep2 is asoociated with some other Form which contains geter,setter for NewTitle

Title : <html:text property="NewTitle" /> This code works.
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A feature of html:xxx tags that is not well documented is that if you put something in the body of the tag, it populates the value attribute.

In your example, this should work:

<html:text property="NewTitle"><bean:write name="OtherBean" property="title"/></html:text >

In my mind, though, the best way to handle this would be to have the action class set the value of myForm.newTitle to OtherBean.title before forwarding to the jsp.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic