I think this particular problem with getElementsByClassName is that
there is a check to see if this method is already a native function by
checking document.getElementsByClassName. On the first pass it sees
that it is not and adds it to document and to Element.Methods. On the
second pass it sees that it is already on document (from the first
pass) and then does not add it to Element.Methods.

It probably works in the other browsers because they can extend the
prototype of DOM elements so the method "stuck" from the first pass.

If you are putting widgets on your page that you don't have control
over it can you sandbox it in an iframe to avoid conflicts. I can
imagine a lot worse conflicts than just duplicate libraries being
loaded.

Darrin

On May 29, 4:24 am, BillyRayPreachersSon
<[EMAIL PROTECTED]> wrote:
> Michael,
>
> We cannot rely on their copy because our page has a need for Prototype
> before their widget is even invoked.
>
> Kangax,
>
> The error is simply "Object doesn't support this property or method"
> when trying to call the "getElementsByClassName" method on an element.
>
> Now, I know that "getElementsByClassName" has been deprecated, but
> this isn't our code so we cannot fix it, We are simply trying to get
> our code to co-exist with theirs.
>
> Thanks,
> Dan
--~--~---------~--~----~------------~-------~--~----~
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@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to