Re: two form one jsp

2006-08-02 Thread Michael Jouravlev
t; serverside scripts > don't read id's. You needn't bother with an id > attribute for a form or > form element unless you want to (a) access it in a > script by means of > document.getElementById() or (b) you want to style it > using a CSS id > selector (e.g. form#myForm or #m

Re: two form one jsp

2006-08-02 Thread Parvat Singh Ranawat
Hi All n Kalpesh, Here I can use seperate formBean but this may not be good practice... actually somebody suggested me to pass the form object as parameter in function while calling java script like

Re: two form one jsp

2006-08-02 Thread kalpesh modi
Is it not possible to use two seperate form beans? -Kalpesh - How low will we go? Check out Yahoo! Messenger’s low PC-to-Phone call rates.

Re: two form one jsp

2006-08-02 Thread Parvat Singh Ranawat
hi , The problem in using document.form[0]. and document.form[1] for first and second form respctively first form comes from Header.jsp and second form from myFoo.jsp and Header is there through out Application and the functionality that is part of Header that I need to write in myFoo.jsp there

Re: two form one jsp

2006-08-01 Thread Monkeyden
Can we please stop suggesting use of the form name? It.will.not.work. If both forms have the same name, it makes a reference to document.forms['foo'] an array and not a reference to the form. Of course you *could *do this: function tellMe(){ alert("Form 1: " + *document.forms['foo'][0].

Re: two form one jsp

2006-08-01 Thread kalpesh modi
I am not sure whether document. form['formName'] will work or not. Give it a try. -Kalpesh - Yahoo! Music Unlimited - Access over 1 million songs.Try it free.

Re: two form one jsp

2006-08-01 Thread Monkeyden
an combine two form to > one but have two > object behind to accept the dat from form you > submit? > > > On 8/1/06, Krishna, Hari <[EMAIL PROTECTED]> > wrote: > > pass the formbean name at run time change the > logic It works for me:) > > > > -Ori

Re: two form one jsp

2006-08-01 Thread Caroline Jen
gt; one but have two > object behind to accept the dat from form you > submit? > > > On 8/1/06, Krishna, Hari <[EMAIL PROTECTED]> > wrote: > > pass the formbean name at run time change the > logic It works for me:) > > > > -Original Message- > &

Re: two form one jsp

2006-08-01 Thread Li
Parvat Singh Ranawat [mailto:[EMAIL PROTECTED] Sent: Monday, July 31, 2006 11:32 PM To: user@struts.apache.org Subject: two form one jsp Hi all, I'm attempting to create a JSP that is made up of two forms. Each form needs a same form bean and is processed by a same action. The catch is that t

RE: two form one jsp

2006-08-01 Thread Krishna, Hari
pass the formbean name at run time change the logic It works for me:) -Original Message- From: Parvat Singh Ranawat [mailto:[EMAIL PROTECTED] Sent: Monday, July 31, 2006 11:32 PM To: user@struts.apache.org Subject: two form one jsp Hi all, I'm attempting to create a JSP that is ma

Re: two form one jsp

2006-07-31 Thread Monkeyden
Your example WILL always point to the first form, since you use the index of 0 (zero). You need to use 1 to point to the second form. This works fine for me: function tellMe(){ alert("Form 1: " + document.forms[0].form2Text.value); alert("Form 2: " + document.forms[1].form2Text.value)

two form one jsp

2006-07-31 Thread Parvat Singh Ranawat
Hi all, I'm attempting to create a JSP that is made up of two forms. Each form needs a same form bean and is processed by a same action. The catch is that the one form comes from Header (This will be there for all the pages as part of left panel ) and second is coming from my jsp and proble