• 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
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

html:option

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

I am using a cobmo box to display values from a collection on a JSP.(I am using struts)
Following is the piece of code:

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
<html:select name="cmPartyToPartyRelationshipsForm" property= "partyToPartyRelationships[0].partyRelationships" styleId= "optBoxShort" >

<html ption value="">

<bean:write name="cmPartyToPartyRelationshipsForm" property="partyToPartyRelationships[0].partyRelationships[0].relationship"/>

</html ption>

</html:select>
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
<i>relationship</i> is a collection of strings and all the values are getting displayed within a single drop down. I want all the values in the collection <i>relationship</i> to be displayed in seperate combo boxes.

I tried inserting </br>, but somehow it doesnt seem to work as all the values are getting printed at once in the combo.

Thanks in advance.
 
pie sneak
Posts: 4727
Mac VI Editor Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hint: you'll need more than one html:select if you want more than one combobox
 
Arch enemy? I mean, I don't like you, but I don't think you qualify as "arch enemy". Here, try this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic