This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes Struts and the fly likes html checkbox tag and checkall javascript functionality results in undefined alert Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Frameworks » Struts
Reply Bookmark "html checkbox tag and checkall javascript functionality results in undefined alert" Watch "html checkbox tag and checkall javascript functionality results in undefined alert" New topic
Author

html checkbox tag and checkall javascript functionality results in undefined alert

sravani jetty
Ranch Hand

Joined: Jun 06, 2007
Posts: 38
Here is my jsp page code that builds the jsp page.


It works perfectly and I can see all the corresponding records for a particular licenseename on the page.

Then I wrote a html check box tag to check all the records that correspond to the particular licensee name as below.



I wrote a javscript function that checks all the checkboxes for the records returned by the above tag and I get an undefined alert. I believe the event variable I am defining in my JS function is not getting any thing.


David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

This is a JavaScript question--not Struts.

While it's inappropriate to discuss this question here, there's nothing in the code you posted named "eventName", so you haven't provided enough information to help anyway.
sravani jetty
Ranch Hand

Joined: Jun 06, 2007
Posts: 38
David,

Sorry, For some reason I was thinking that the value is not being returned because of struts error. after I made this post, I figured that the problem lies in the check_all function call without any parameters, in html check box struts tag.

Eventname is a property that is set in actionform.

Thanks for your quick response and if you have the moderator rights, please feel free to move this to the javascript forums
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: html checkbox tag and checkall javascript functionality results in undefined alert
 
Similar Threads
how to use- html:checkbox - and iterate it through - logic:iterate
Need Help with binding click events to table rows
Read the respective row when a check box checked
Fetch the correspondin row using the checkbox checked value
not able to call javascript function on onlcick