JQuery Not working in Drupal

Reply

Join Date: Aug 2009
Posts: 15
Reputation: chavansoft is an unknown quantity at this point 
Solved Threads: 0
chavansoft chavansoft is offline Offline
Newbie Poster

JQuery Not working in Drupal

 
0
  #1
Aug 31st, 2009
Hi,

JQuery Not working in Drupal, Please help me fixing it. The below is my JQuery code.

  1. $(document).ready(function(){
  2. $('#slides').cycle({
  3. fx: 'fade',
  4. speed: '300',
  5. timeout: 6000,
  6. delay: -2000,
  7. next: '#next',
  8. prev: '#prev'
  9.  
  10. });
  11.  
  12. function onBefore() {$('#title').html(this.title);}
  13. });

Regards
Reply With Quote Quick reply to this message  
Join Date: Aug 2007
Posts: 189
Reputation: martin5211 is an unknown quantity at this point 
Solved Threads: 14
martin5211 martin5211 is offline Offline
Junior Poster

Re: JQuery Not working in Drupal

 
0
  #2
Sep 1st, 2009
The jQuery questions should be made on JavaScript / DHTML / AJAX forum.

From Drupal perspective, some jQuery plugins could not work with the jQuery bundle included on Drupal core (the jQuery distribution included maybe is too old). To fix this issue, there is a module to update the jQuery distribution: http://drupal.org/project/jquery_update

Looking at your code, use comments into OnBefore() line to test the cycle plugin alone. title isn't a defined object. Try to use a jQuery selector instead.
Last edited by martin5211; Sep 1st, 2009 at 1:20 pm.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC