Create an account

Very important

  • To access the important data of the forums, you must be active in each forum and especially in the leaks and database leaks section, send data and after sending the data and activity, data and important content will be opened and visible for you.
  • You will only see chat messages from people who are at or below your level.
  • More than 500,000 database leaks and millions of account leaks are waiting for you, so access and view with more activity.
  • Many important data are inactive and inaccessible for you, so open them with activity. (This will be done automatically)


Thread Rating:
  • 735 Vote(s) - 3.53 Average
  • 1
  • 2
  • 3
  • 4
  • 5
jQuery issue - #<an Object> has no method

#1
I've tried a veriety of jQuery plugins recently and I keep getting this error …

[![has no method][1]][1]
<sub>(source: [shaunbellis.co.uk](

[To see links please register here]

;



… regardless of what plugin I try to use.

I've checked the links to the JS files which are all there and working fine. I'm using Drupal if that makes any difference.

I've run the plugins away from the main site to demonstrate that they are working and that I am doing things right with 100% success.

Any ideas?

Update:

My jQuery file called in the footer:

$(document).ready(function() {

$('#footer_holder').hide();

// Fancy Box
$("a.fancybox").fancybox({
'hideOnContentClick': true,
'titlePosition' : 'over',
'transitionIn' : 'elastic',
'transitionOut' : 'elastic',
'speedIn' : 600,
'speedOut' : 200,
'overlayShow' : false,
});

$("#homepage_slider").easySlider({
auto: true,
continuous: true,
});

});

*note - fancy box works fine (unless the easySlider code is above it). jQuery is sorted out by Drupal. I'm running version 1.4


[1]:
Reply

#2
Ignore me. I'm sorry everyone. I'd mistyped the url of the script. Thanks to Simon Ainley for the prod in the right direction.

Sorry again. Thanks.
Reply

#3
I had this problem, or one that looked superficially similar, yesterday. It turned out that I wasn't being careful when mixing jQuery and prototype. I found several solutions at

[To see links please register here]

. I opted for

var $j = jQuery.noConflict();

but there are other reasonable options described there.
Reply

#4
For anyone else arriving at this question:

I was performing the most simple jQuery, trying to hide an element:

('#fileselection').hide();

and I was getting the same type of error, "**Uncaught TypeError: Object #fileselection has no method 'hide'**

Of course, now it is obvious, but I just left off the jQuery indicator '$'. The code should have been:

$('#fileselection').hide();

This fixes the no-brainer problem. I hope this helps someone save a few minutes debugging!
Reply

#5
This problem may also come up if you include different versions of jQuery.
Reply

#6
This usually has to do with a selector not being used properly. Check and make sure that you are using the jQuery selectors like intended. For example I had this problem when creating a click method:

$("[editButton]").click(function () {
this.css("color", "red");
});
Because I was not using the correct selector method $(this) for jQuery it gave me the same error.

So simply enough, check your selectors!
Reply

#7
This problem can also arise if you include jQuery more than once.
Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

©0Day  2016 - 2023 | All Rights Reserved.  Made with    for the community. Connected through