This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Struts and the fly likes <s:property value= problen in Struts2" title="" /> Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "<s:property value="#request.firstName"  escape=" " default=" "/> problen in Struts2" Watch "<s:property value="#request.firstName"  escape=" " default=" "/> problen in Struts2" New topic
Author

<s:property value="#request.firstName" escape=" " default=" "/> problen in Struts2

Hrishikesh Maluskar
Ranch Hand

Joined: Jun 19, 2008
Posts: 115
In the following code i want to display a blank space by default , but in this case it is displaying "/".

Also i want to know the significance of escape attribute.



SCJP 1.5
www.licexpadvice.com
Ahmed M. Omar
Ranch Hand

Joined: Mar 02, 2010
Posts: 43
try


regards
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

To answer the escape question:

http://struts.apache.org/2.x/docs/property.html

It will display whatever is in firstName; there's no way it would display a "/" unless either there's a "/" in the firstName or there's something else wrong with the page. Although I'm not sure what an empty string for the "escape" attribute would do--I agree that it should be removed.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: <s:property value="#request.firstName" escape=" " default=" "/> problen in Struts2
 
Similar Threads
Struts2 Iteator Tag with object in object
> expected error in JSP (struts 2)
how to use ONGL ?
<s:iterator
setting session variable in hidden control