Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't work in IE8 #15

Open
BB-000 opened this issue Jun 21, 2016 · 1 comment
Open

Doesn't work in IE8 #15

BB-000 opened this issue Jun 21, 2016 · 1 comment

Comments

@BB-000
Copy link

BB-000 commented Jun 21, 2016

SCRIPT5007: Unable to get property 'path' of undefined or null reference 
lazyYT.js, line 221 character 7

:(

IE8 doesn't get any of the Youtube info ( thumbnail / title ) and gets stuck on the blank ' loading... ' screen. This screen can be clicked which then inserts the iframe...

Can be replicated on the demo page [http://works.daugilas.com/lazyYT/demo/fluid.html]

Any workarounds for this?

@BB-000
Copy link
Author

BB-000 commented Jun 21, 2016

I found a workaround,

The problem was this function, the data parameter was always 'undefined' in < IE9

function getOnloadDataParam(data, key) { ... }

So I just added the below as the first if statement. Returning nothing seems to work fine, as the rest of the loadBackgroundImage function sorts it out. ( adding any number under 700 makes the background black for some reason? )

if (typeof data == 'undefined') {
        return;
      } else if ....

So this works, let me know if there's a better way of doing this though :]

Also IE8 *edit( IE9 ) couldn't fetch the video title, so I just set display_title to false in < IE10
( I assume it is something to do with the Youtube API not working in these retro browsers? )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant