PDA

View Full Version : Image Crawler - doesn't show images in IE 8



AnqaKar
10-06-2014, 07:46 PM
1) Script Title: Image Crawler

2) Script URL (on DD): http://test2.slowotwor.com/

3) Describe problem: I cannot see the images in IE 8. It seems that the script deasn't work. In FF, Chrome and Opera works fine.
Please help!

jscheuer1
10-06-2014, 11:35 PM
Always worked fine in IE 8 here. I think I see the problem. Here:


<script type="text/javascript">
marqueeInit({
uniqueid: 'crawler-logos',
style: {
'padding': '10px',
'max-width': '1190px',
'height': '90px',
'width': '100%!important',
},
inc: 8, //speed - pixel increment for each iteration of this marquee's movement
mouse: 'cursor driven', //mouseover behavior ('pause' 'cursor driven' or false)
moveatleast: 2,
neutral: 150,
random: true,
addDelay: 30,
savedirection: true,
});
</script>


See the red coma? It's technically invalid, get rid of it (there should be no coma after the last item in an array, nor after the last member of an object). Most browsers will error correct this for you. IE 8 and earlier will not.

There could also be other problems, but - since it works in other browsers, that's probably it.

The browser cache may need to be cleared, and/or the page refreshed to see changes.

AnqaKar
10-07-2014, 01:56 PM
Hi John!

Thank you for your support!

Unfortunately, I delete this come and nothing changes.
I will be grateful for any other advices.

Anna

jscheuer1
10-07-2014, 03:53 PM
I'm really not sure what to tell you. First of all, even without IE, there's something fundamentally off about the layout. You should not need 'width ':'100%!important'. And for IE 8, it can't be, and it cannot have a trailing comma for the same reason I mentioned before. The page also cannot have jQuery 2.1.1 because that doesn't support IE 8. But I think we can work around all of that, mostly.

Get rid of:


<script src="http://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>

Add the highlighted, as shown:


<link rel="stylesheet" href="http://test2.slowotwor.com/wp-content/themes/janal-theme/reset.css" type="text/css">
<link rel="stylesheet" href="http://test2.slowotwor.com/wp-content/themes/janal-theme/style.css" type="text/css">
<link rel="stylesheet" href="http://test2.slowotwor.com/wp-content/themes/janal-theme/style-typography.css" type="text/css">
<link rel="stylesheet" href="http://test2.slowotwor.com/wp-content/themes/janal-theme/stylesheet-fonts.css" type="text/css">
<style type="text/css">
.marquee0, .marquee0 div {width: 100% !important;}
</style>


Change:


<script type="text/javascript">
marqueeInit({
uniqueid: 'crawler-logos',
style: {
'padding': '10px',
'max-width': '1190px',
'height': '90px',
'width': '100%!important',
},
inc: 8, //speed - pixel increment for each iteration of this marquee's movement
mouse: 'cursor driven', //mouseover behavior ('pause' 'cursor driven' or false)
moveatleast: 2,
neutral: 150,
random: true,
addDelay: 30,
savedirection: true
});
</script>

to (without the !important and without the comma):


<script type="text/javascript">
marqueeInit({
uniqueid: 'crawler-logos',
style: {
'padding': '10px',
'max-width': '1190px',
'height': '90px',
'width': '100%'
},
inc: 8, //speed - pixel increment for each iteration of this marquee's movement
mouse: 'cursor driven', //mouseover behavior ('pause' 'cursor driven' or false)
moveatleast: 2,
neutral: 150,
random: true,
addDelay: 30,
savedirection: true
});
</script>

That should do it now.

AnqaKar
10-07-2014, 04:20 PM
John!
Thank you very much for all hints and advices - I delete jQuery 2.11, I correct the CSS inside JS and on the beginning nothing change.
Additionally, I add this JS code inside the body, on the bottom of the site and it works!

I do not know why exactly nut meybe is some wordpress issue or my mistake.

Thank you once again!
The problem is resolved!
Cheers!