help to using an array checkbox in javascript

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

User avatar
Redcircle
Moderator
Moderator
Posts: 830
Joined: Tue Jan 21, 2003 10:42 pm
Location: Michigan USA
Contact:

Postby Redcircle » Thu Jul 03, 2003 7:34 am

s it the fact that Javascript desn't understand the [] at the end of the name's checkbox.
Javascript errors "object.length is null or not an object". Unfortunately I need the [] there
as they are to be processed by some php when I submit the form.


You are correct. Instead of using the actual object name you will need to use the element id.

document.element[id].checked

set the id numerically and it should work.

Return to “PHP coding => General”

Who is online

Users browsing this forum: No registered users and 2 guests