mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
MINOR Added prototypefix helper scripts from jquery13 module to fix document.getElementsByClassName() override by prototypejs
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@92548 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
76d2886a70
commit
32c44b071d
7
javascript/prototypefix/README
Normal file
7
javascript/prototypefix/README
Normal file
@ -0,0 +1,7 @@
|
||||
Prototype replaces document.getElementsByClassName with it's own version. However many browsers
|
||||
now come with their own implementation, and prototype's is much slower.
|
||||
|
||||
This fixes this by restoring the original after prototype is loaded.
|
||||
|
||||
@todo: Safari 3 used to come with a broken document.getElementsByClassName. We should use
|
||||
the same checks jQuery does and not restore the function if it doesn't work the same as the spec.
|
1
javascript/prototypefix/intro.js
vendored
Normal file
1
javascript/prototypefix/intro.js
vendored
Normal file
@ -0,0 +1 @@
|
||||
var browserGetElementsByClassName = document.getElementsByClassName;
|
1
javascript/prototypefix/outro.js
vendored
Normal file
1
javascript/prototypefix/outro.js
vendored
Normal file
@ -0,0 +1 @@
|
||||
if (browserGetElementsByClassName) document.getElementsByClassName = browserGetElementsByClassName;
|
Loading…
x
Reference in New Issue
Block a user