?
Solved

JS error on motools-core.js

Posted on 2011-05-05
10
Medium Priority
?
730 Views
Last Modified: 2012-05-11
I get this error when I view my page on ie 8, it's ok on FF and IE9:

Message: Invalid argument.
Line: 1
Char: 56604
Code: 0
URI: http://www.shibly.net/web/media/system/js/mootools-core.js

Attached is a copy of the code at hand from ch 56430 to 56632





This one really got me stuck!

f=Array.from(f).map(function(k,j){if(!h[j]){return""}return(typeOf(k)=="number")?h[j].replace("@",Math.round(k)):k}).join(" ")}else{if(f==String(Number(f))){f=Math.round(f)}}this.style[g]=f;return this}

Open in new window

0
Comment
Question by:aboo_s
  • 6
  • 4
10 Comments
 
LVL 10

Author Comment

by:aboo_s
ID: 35699806
My page URL is:

www.shibly.net/web
0
 
LVL 83

Expert Comment

by:leakim971
ID: 35762488
Try to set the width of the images
If it don't work replace slideshow.push.min.js by the one attached.
slideshow.push.min.txt
0
 
LVL 83

Expert Comment

by:leakim971
ID: 35762490
don't forget to rename it with the right extension txt -> js
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 10

Author Comment

by:aboo_s
ID: 35762542
Thanks leakim971,
The slideshow module has the option of setting width and height of images from backend side
and did not change a thing!
As for the slideshow.push.min.js , I still am getting the same error!
0
 
LVL 83

Accepted Solution

by:
leakim971 earned 2000 total points
ID: 35762553
Sorry, try this one :
slideshow.push.min.txt
0
 
LVL 10

Author Comment

by:aboo_s
ID: 35763660
It works like charm!

I want to thank you very much, that the first thing!
The second I want to ask what the problem was? if it is not trouble to explain!
0
 
LVL 10

Author Comment

by:aboo_s
ID: 35763665
I accidentally pressed this button I want to cancel it!
0
 
LVL 10

Author Closing Comment

by:aboo_s
ID: 35763667
Thanks!
0
 
LVL 83

Expert Comment

by:leakim971
ID: 35764104
The error was on : this.style[g]=f
Where :
g equal to : left
f was NaN (not a number) that's why we get an error

This part of code is called by b[1].set("styles",{left:"auto",right:"auto"}).setStyle(this.direction,d); in slideshow.push.min.js
We've :
var d=this.width-((b[1].width!=null)?b[1].width:this.width); // initialty var d=this.width-b[1].width;
b[1].set("styles",{left:"auto",right:"auto"}).setStyle(this.direction,d);

On IE b[1].width is null (undefined)
b is the array of images (span with the background as image)

The code i more readable here : http://code.google.com/p/slideshow/source/browse/trunk/mootools/slideshow.push.js?r=148
The lines 51 and 52
var width = this.width - images[1].width;

replaced by :

var width = this.width - ((images[1].width!=null)?images[1].width:this.width)?;

Open in new window

0
 
LVL 10

Author Comment

by:aboo_s
ID: 35765126
Thanks for your fast response, you've been much help!
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Does your audience prefer people in photos or no people? How can you best highlight what you’re selling? What are your competitors doing, and what can you do that is different and unique from them?  Continue reading to learn how to make your images …
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
This video teaches users how to migrate an existing Wordpress website to a new domain.
The viewer will learn how to dynamically set the form action using jQuery.
Suggested Courses
Course of the Month16 days, 8 hours left to enroll

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question