On Jan 9, 7:04 pm, cyiam <[email protected]> wrote:
[...]
> HELP!
>
> The javascript looks as below:
>
> $('removeFeature').observe('click',function(){
> var deletedFeatures = $A($F('features'));
> deletedFeatures.each(
> function(feature){
> $(feature).remove();
> });
> });
Try something like:
$('removeFeature').observe('click',function() {
$A($('features').options).findAll(function(el) {
return el.selected;
}).invoke('remove');
});
P.S. It would be nice if there was a support for `:selected` css
pseudo class
--
kangax
--~--~---------~--~----~------------~-------~--~----~
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 [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---