Hi

I have a few site features such as a jquery slideshow which I am displaying on my front page.

I setup a content type called slideshow, created a view, edited the views templates to match the layout required by the jquery slideshow script. I the installed the jQuery update module and set it to jquery1.10 but the slideshow script didn't work. I then proceeded to adding a link to jquery1.10 in my themes .info file and then the slideshow worked perfectly.

Here the trouble comes in though. I have a ajax webform that was acting fine until I added jquery1.10 to the .info file. Now when i click submit on the webform i get a error stating "a error occurred while attempting to process /sitename/system/ajax:$fieldValue is not a function"

I really dont have a clue what the issue is here. If anyone could give some guidance it would greatly be appreciated.

Comments

UNarmed’s picture

When i remove the jquery.js from the .info file the ajax webform works fine but then none of my sliders that rely on jquery work.

Jaypan’s picture

It sounds like there is a conflict between the versions that the slideshow and webform work with. You'll likely have to find a different slideshow, or an alternative to webform.

UNarmed’s picture

Hi I managed to solve the issue, below are the steps i followed.

  1. I removed the reference to jquery1.10 in my .info file
  2. I then set the jquery module to use jquery 1.10
  3. I then wrapped by slideshow jquery in the following tags
    (function ($) {
      // Original JavaScript code.
    })(jQuery);

Additional information on the cause of the issue can be found here https://www.drupal.org/docs/7/theming/working-with-javascript-and-jquery