• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

bean:write, with PRE in OPTION tag

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

I have tried to write a bean: write tag in the Option tag, I want preseve the spaces So I used the <PRE> tag before and after the <bean:write> tag , but it is working when it is used individually, its not working when It is used in Html Option tag, is there any other way to preseve the space and I can not change the tag source as I am using standard taglibs.


<select name="selectedItem" '>
<logic:iterate id="data1" name=" DATA" type="com.xxxx.xxx.xData">
<option value='<bean:write name="data1" property="nrr"/>'>
<bean:write name="data1" property="nrr"/>
</option>
</logic:iterate>
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please be sure to post Struts questions in the Struts forum. I have moved this there for you.
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Try using & n b s p ; (without the spaces) for each space you want inserted.
 
Madhu panitini
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
its not possible to use   as I am getting the data from the <bean:write name="data1" property="nrr"/> and I found some how bean:write tag is removing the spaces and I want the string data from bean to be written as it gets from data1 bean, as I mentioned in my earlier post, I even tried with the <pre> tag, but its not working
 
A teeny tiny vulgar attempt to get you to buy our stuff
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic