struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Amit Kumar Sharma" <amit...@sysarris.soft.net>
Subject RE: Dots in form names creates problems with Javascript Validator function names
Date Wed, 01 Sep 2004 08:25:07 GMT
Hi,

Instead of using for names in that case use.


This should not give any problem := Documet.forms[0].elements[0]

When formname and somename has dots in between.
Accessing elements in this fashion will give problem :=
Documet.formname.getElementsById("somename")

I mean to say access the elements and forms as objects not as names.Do
some minor changes to the validator java scripts formed.

Regards
Amit


-----Original Message-----
From: Kunal Parikh [mailto:kunalp@carsales.com.au] 
Sent: Wednesday, September 01, 2004 10:30 AM
To: user@struts.apache.org
Subject: Dots in form names creates problems with Javascript Validator
function names

Hi!

I have some forms with dots in their names.

The problem is that the JS validation code being generated is not quite

right

Is there a resolution/work-around to this issue ?

e.g.

FormName: employer.search
JS generated:

=============

     function employer.search_required () {
	...
	...
     }

     function employer.search_email () {
	...
	...
     }

=============


TIA,

Kunal


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message