rickyduck
rickyduck

Reputation: 4084

IE8 only - Object doesn't support property or method 'widget'

I am getting an error related to [jCoverflip][1] that only occurs in IE8. The following error occurs:

SCRIPT438: Object doesn't support property or method 'widget' jquery.jcoverflip.js, line 508 character 1

which relates to the following code:

$.widget( 'ui.jcoverflip', {

I have jQuery and jQueryUI both included, before the script, plus the script runs fine in all other browsers.

Whats causing the issue?

Upvotes: 6

Views: 13588

Answers (2)

user3323009
user3323009

Reputation: 21

I had similiar problem. There is jquery.ui.widget.js which wasn't included. My problem got solved after including it.

Upvotes: 2

T.J. Crowder
T.J. Crowder

Reputation: 1075009

You seem to be loading jquery twice:

<!-- First here -->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script type="text/javascript" src="/./scripts/jquery-ui-1.7.2.custom.js"></script>
<!-- Then again here -->
<script type="text/javascript" src="/scripts/jquery.js"></script>

They appear to be v1.3.2 and v1.0.4 (!), respectively. Those are completely out of date. I don't know what jQuery UI 1.7.2's requirements are, but I'm sure v1.0.4 won't do it. v1.3.2 might, jQuery UI 1.7.2 is a couple of years old. (You might at least look at jQuery UI 1.7.3, which says it's for jQuery v1.3.2.)

Also, you're using MooTools on the page, but I don't immediately see where you're calling jQuery.noConflict() (I didn't go digging all that deep). That could well be the problem, MooTools and jQuery both try to use $. To avoid a conflict, immediately after loading jQuery, do this:

<script>
jQuery.noConflict();
</script>

Upvotes: 5

Related Questions