Solved

struts html:option problem

Posted on 2004-09-23
4
280 Views
Last Modified: 2010-03-31
Hai,

I have:

<html:select property="projects" multiple="" style="width:70%;">
      <logic:iterate name="projekteAndAufgabe" id="projekt">
      <logic:iterate name="projekt" property="aufgabeViews" id="aufgabe">
           <html:option value="test">
                        <bean:write name="projekt" property="projektNummer" />
                       <bean:write name="projekt" property="bezeichnung" /> --
                     <bean:write name="aufgabe" property="nummer" />
                    <bean:write name="aufgabe" property="kurzBeschreibung" />
           </html:option>
      </logic:iterate>
       <logic:iterate>
</html:select>

but i have the option value as "test", i want it to be replaced it with *bean content* which is present inside the option tag.

PS: I cannot use collections here.

Not sure if it is simple, but i go with maximum points since it is urgent. Any ideas ?
0
Comment
Question by:ldbkutty
  • 3
4 Comments
 
LVL 37

Expert Comment

by:zzynx
ID: 12132149
0
 
LVL 37

Accepted Solution

by:
zzynx earned 500 total points
ID: 12132236
0
 
LVL 32

Author Comment

by:ldbkutty
ID: 12132330
>> Does this help?
YES !!! :-)

For future reference, i will post the solution here:

<html:select property="projects" multiple="" style="width:70%;" styleClass="zeiterfassung_data">
                                                                  <logic:iterate name="projekteAndAufgabe" id="projekt">
                                                                        <logic:iterate name="projekt" property="aufgabeViews" id="aufgabe">
                                                                              <html:option value="${projekt.projektNummer} -- ${aufgabe.nummer}">
                                                                              <bean:write name="projekt" property="projektNummer" />
                                                                              <bean:write name="projekt" property="bezeichnung" /> --
                                                                              <bean:write name="aufgabe" property="nummer" />
                                                                              <bean:write name="aufgabe" property="kurzBeschreibung" />
                                                                              </html:option>
                                                                        </logic:iterate>
                                                                  </logic:iterate>
                                                                  
                                                            </html:select>
0
 
LVL 37

Expert Comment

by:zzynx
ID: 12132344
>>>> Does this help?
>>YES !!! :-)

:°)))

Thanks for accepting
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
split53 challenge 7 96
more than one jdk and one jre 1 41
jdbc error in jsp application 20 45
Which non-HTML GUI front end to use with Java? 3 22
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question