Re: [Proto-Scripty] Re: click one checkbox will submit only one checkbox value (not the whole form) immediately

2010-03-11 Thread Douglas
Well, this has nothing to do with prototype, but you might use
Prototype's Ajax.Request[1] to send only the data from the checked
input (as follow):

e.g.:






function myMubmit(input) {
  new Ajax.Request(url, {
method: 'post',
parameters: input.name +'='+input.value,
onSuccess: function(r) {
  // show the result or do something wild
}
  });
}

You can also use Prototype's Event.observe[2] to check the click event
on each checkbox.

[1] http://api.prototypejs.org/ajax/ajax/request.html
[2] http://api.prototypejs.org/dom/event.html#observe-class_method

Cheers,

On Thu, Mar 11, 2010 at 12:50 PM, albert kao  wrote:
> What is the function submitjustthisone() look like?
>
> On Feb 23, 9:54 pm, Al C  wrote:
>> Albert - change the onclick to point to a javascript
>> e.g.,
>>  > onclick="submitjustthisone();">
>>
>> Of course, youwillalso need to write this function
>> 
>> function submitjustthisone(){
>> //do the stuff you need to do}
>>
>> 
>>
>> On Feb 23, 4:58 pm, albert kao  wrote:
>>
>>
>>
>> > My JSP web page has many checkboxes.
>> > What is web page source code look like when clickingonecheckboxwill
>> >submitonlyonecheckboxvalue(not the whole form) immediately?
>> > i.e. togglingonecheckboxwillsend the info thatonlythatcheckbox
>> > is toggled.
>> > This does not work because clickingonecheckboxwillsend the whole
>> > page
>> > 
>> > 
>> > 
>> > 
>> > ...
>
> --
> 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-scriptacul...@googlegroups.com.
> To unsubscribe from this group, send email to 
> prototype-scriptaculous+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/prototype-scriptaculous?hl=en.
>
>



-- 
D. G. Rodrigues
Consultoria e Auditoria em Desenvolvimento de Softwares

Believe nothing, no matter where you read it or who said it, unless it
agrees with your own reason and your own common sense.

-- 
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-scriptacul...@googlegroups.com.
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en.



[Proto-Scripty] Re: click one checkbox will submit only one checkbox value (not the whole form) immediately

2010-03-11 Thread albert kao
What is the function submitjustthisone() look like?

On Feb 23, 9:54 pm, Al C  wrote:
> Albert - change the onclick to point to a javascript
> e.g.,
>   onclick="submitjustthisone();">
>
> Of course, youwillalso need to write this function
> 
> function submitjustthisone(){
> //do the stuff you need to do}
>
> 
>
> On Feb 23, 4:58 pm, albert kao  wrote:
>
>
>
> > My JSP web page has many checkboxes.
> > What is web page source code look like when clickingonecheckboxwill
> >submitonlyonecheckboxvalue(not the whole form) immediately?
> > i.e. togglingonecheckboxwillsend the info thatonlythatcheckbox
> > is toggled.
> > This does not work because clickingonecheckboxwillsend the whole
> > page
> > 
> > 
> > 
> > 
> > ...

-- 
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-scriptacul...@googlegroups.com.
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en.



[Proto-Scripty] Re: click one checkbox will submit only one checkbox value (not the whole form) immediately

2010-02-23 Thread Al C
Albert - change the onclick to point to a javascript
e.g.,
 

Of course, you will also need to write this function

function submitjustthisone(){
//do the stuff you need to do
}


On Feb 23, 4:58 pm, albert kao  wrote:
> My JSP web page has many checkboxes.
> What is web page source code look like when clicking one checkbox will
> submit only one checkbox value (not the whole form) immediately?
> i.e. toggling one checkbox will send the info that only that checkbox
> is toggled.
> This does not work because clicking one checkbox will send the whole
> page
> 
> 
> 
> 
> ...

-- 
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-scriptacul...@googlegroups.com.
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en.