For example:
<input name="ApprovedSubscribers" value="123" type="checkbox" checked="checked"/> Joe Cool
<input name="ApprovedSubscribers" value="456" type="checkbox" /> Fred Flintstone
<input name="ApprovedSubscribers" value="789" type="checkbox" checked="checked" /> Barney Rubble
Becomes ApprovedSubscribers="123, 789" when submitted.
You can then observe the form for changes and submit via ajax with a normal form submit for graceful degradation.
Brian Marquis | Quotepro® | Senior Developer | bm@quotepro.com | Phone: 312.654.8045 x122 / Fax: 312.654.1285
![]()
The information in this e-mail is confidential and may be legally privileged. It is intended solely for the addressee. Access to this e-mail by anyone else is unauthorized.
--
You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group.
To post to this group, send email to prototype-s...@googlegroups.com.
To unsubscribe from this group, send email to prototype-scripta...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en.
A few options for event listeners (untested):
$('tableid').observe('click',function(event) {
var element = Event.element(event);
if ( element.name == " ApprovedSubscribers" ) {
new Ajax.Request( url, $H({ RecordId: element.value, Checked: element.checked }));
}
});
Or
$$("input[type='checkbox']").invoke("observe","click",function(event) {
var element = Event.element(event);
if ( element.name == " ApprovedSubscribers" ) {
new Ajax.Request( url, $H({ RecordId: element.value, Checked: element.checked }));
}
});