Solved

hidden Variables

Posted on 2006-06-26
4
339 Views
Last Modified: 2010-03-31
I am supposed to write a form in struts. The issue is I have to populate some of the values  of this form into other form using hidden variables. I am not aware of how to use it thoe I know the theory behind the hidden variables. I will be pleased if anyone could show me a sample code of few lines, so I can get how things work.
0
Comment
Question by:rmvprasad
  • 2
4 Comments
 
LVL 92

Expert Comment

by:objects
ID: 16989574
add input tag insoide your form fopr each hidden var

<input type="hidden" name="varname" value="varvalue"/>
0
 
LVL 35

Expert Comment

by:girionis
ID: 16990372
For more info have a look here: http://www.tizag.com/htmlT/htmlhidden.php
0
 
LVL 3

Accepted Solution

by:
ss_p earned 125 total points
ID: 17009546

a.jsp
<input type="hidden" name="username" value="username"/>

b.jsp

<%
String userName = (String)request.getSession().getAttribute("username");
%>

Is this wat you want
0
 
LVL 3

Expert Comment

by:ss_p
ID: 17016344
did my code help you my friend
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

For customizing the look of your lightweight component and making it look opaque like it was made of plastic.  This tip assumes your component to be of rectangular shape and completely opaque.   (CODE)
This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

867 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now