Re: How o display a hashtable in jsp
you can use c:forEach items="MappedVariable" take a look at http://www-128.ibm.com/developerworks/java/library/j-jstl0318/ Viel Gluck, Martin-- This email message and any files transmitted with it contain confidential information intended only for the person(s) to whom this email message is addressed. If you have received this email message in error, please notify the sender immediately by telephone or email and destroy the original message without making a copy. Thank you. - Original Message - From: "Martin Kindler" <[EMAIL PROTECTED]> To: "'Struts Users Mailing List'" ; <[EMAIL PROTECTED]> Sent: Monday, June 26, 2006 5:38 AM Subject: AW: How o display a hashtable in jsp Hi Pankaj, if you use JSTL you can have a java.util.Map as the collection type you are iterating over. The only trick is that the item you operate on in each iteration is a java.util.Map.Entry, i.e. you must access its key/value accordingly. The same is true, if you are using Struts logic tags. Martin -Ursprüngliche Nachricht- Von: Tejas Bavishi [mailto:[EMAIL PROTECTED] Gesendet: Montag, 26. Juni 2006 11:06 An: 'Struts Users Mailing List' Betreff: RE: How o display a hashtable in jsp Hi Pankaj Not sure if this can be done by the tag, may be others can comment. But you can definitely do this using a scriptlet. Hashtable has keys() method that returns an Enumeration of keys. You can traverse through this enumeration to print the keys and corresponding values. Hope that helps Regards Tejas -Original Message- From: Pankaj Gupta [mailto:[EMAIL PROTECTED] Sent: Saturday, June 24, 2006 2:04 PM To: Struts Users Mailing List Subject: How o display a hashtable in jsp Hi, Can you please suggest how can I display key and value(both) from a hashtable in my jsp. Currently I am using the following approach but it prints only the value and not the key. regards, Pankaj - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://www.patni.com World-Wide Partnerships. World-Class Solutions. _ This e-mail message may contain proprietary, confidential or legally privileged information for the sole use of the person or entity to whom this message was originally addressed. Any review, e-transmission dissemination or other use of or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you have received this e-mail in error kindly delete this e-mail from your records. If it appears that this mail has been forwarded to you without proper authority, please notify us immediately at [EMAIL PROTECTED] and delete this mail. _ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How o display a hashtable in jsp
Hi Pankaj, Try using inside logic:iterate I have not tried it. It may work. Regards, Nagesh -Original Message- From: Tejas Bavishi [mailto:[EMAIL PROTECTED] Sent: Monday, June 26, 2006 2:36 PM To: 'Struts Users Mailing List' Subject: RE: How o display a hashtable in jsp Hi Pankaj Not sure if this can be done by the tag, may be others can comment. But you can definitely do this using a scriptlet. Hashtable has keys() method that returns an Enumeration of keys. You can traverse through this enumeration to print the keys and corresponding values. Hope that helps Regards Tejas -Original Message- From: Pankaj Gupta [mailto:[EMAIL PROTECTED] Sent: Saturday, June 24, 2006 2:04 PM To: Struts Users Mailing List Subject: How o display a hashtable in jsp Hi, Can you please suggest how can I display key and value(both) from a hashtable in my jsp. Currently I am using the following approach but it prints only the value and not the key. regards, Pankaj - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://www.patni.com World-Wide Partnerships. World-Class Solutions. _ This e-mail message may contain proprietary, confidential or legally privileged information for the sole use of the person or entity to whom this message was originally addressed. Any review, e-transmission dissemination or other use of or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you have received this e-mail in error kindly delete this e-mail from your records. If it appears that this mail has been forwarded to you without proper authority, please notify us immediately at [EMAIL PROTECTED] and delete this mail. _ The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments. WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email. www.wipro.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How o display a hashtable in jsp
Hi Pankaj Not sure if this can be done by the tag, may be others can comment. But you can definitely do this using a scriptlet. Hashtable has keys() method that returns an Enumeration of keys. You can traverse through this enumeration to print the keys and corresponding values. Hope that helps Regards Tejas -Original Message- From: Pankaj Gupta [mailto:[EMAIL PROTECTED] Sent: Saturday, June 24, 2006 2:04 PM To: Struts Users Mailing List Subject: How o display a hashtable in jsp Hi, Can you please suggest how can I display key and value(both) from a hashtable in my jsp. Currently I am using the following approach but it prints only the value and not the key. regards, Pankaj - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://www.patni.com World-Wide Partnerships. World-Class Solutions. _ This e-mail message may contain proprietary, confidential or legally privileged information for the sole use of the person or entity to whom this message was originally addressed. Any review, e-transmission dissemination or other use of or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you have received this e-mail in error kindly delete this e-mail from your records. If it appears that this mail has been forwarded to you without proper authority, please notify us immediately at [EMAIL PROTECTED] and delete this mail. _ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]