Hi,
to clone an array of DOM objects, I used the following code, which
works perfectly in Firefox:
return this.items.invoke(''cloneNode'', false).map($);
But in IE7 invoke() fails due to the nonexistence of the apply()
method on DOM methods like cloneNode(). Now I use this workaround with
each():
var items = [];
this.items.each(
function(item, i) {
items[i] =item.cloneNode(false);
}
);
return items.map($);
Is there another solution available or is it planned to implement a
solution in Prototype like this one?
http://my.opera.com/_Grey_/blog/2007/04/15/wrapping-ies-dom-functions
Greetings from Germany,
Mensler
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Spinoffs" group.
To post to this group, send email to
rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---