Are you saying that you are then using two versions of jQuery on those pages? That would be unfortunate, of course. But manageable.
I'd be interested in seeing your solution. I did think about that, and so JSmol wraps all references to jQuery, and all references (are supposed to be) in one single file, JSmolCore.js, in one single place. On line 219 of JSmolCore.js we see: (function (Jmol, $) { which ends up at the end of that file as })(Jmol, jQuery); There are no other references to jQuery or $ throughout the entire package. But I can imagine that jQuery *itself* may have some issues with that. Do show me what you have figured out. Bob On Mon, Sep 21, 2015 at 8:58 AM, Eelco van Dam <eelco.van....@peacs.nl> wrote: > L.S., > > > > We are well on the way finishing an educational module to teach students > the basics of spectroscopy using a Drupal 7 website and JSmol and its > JSpecView companion. If you are interested, visit www.eduspec.org. There > is also a demo to the educational content for which a link can be found on > that same site. You need to generate a temporary account for that. > > > > Regarding the use of JSmol in our questions we have a problem with the use > of JQuery in both JSmol and Drupal where the Drupal version of JQuery is > older than the one used by JSmol resulting in a conflict. > > We managed to work around the conflict by adjusting the JavaScript code > for JSmol. The basis of the problem is that JSmol registers its version of > JQuery globally, thus overwriting the JQuery version of Drupal. By > adjusting the JSmol sources so that its JQuery version is now in a > ‘closure’ with JSmol we prevent this from happening. > > > > The problem we have with this solution is that we have to do it for each > upgrade of JSmol preventing us from upgrading. And because this might be a > problem for more teams then ours alone, we thought to bring this to your > attention. > > Would it be an idea to incorporate this adjustment in the JSmol sources? > It only concerns the JSmol version with enclosed JQuery. > > > > Kind regards, > > > > Eelco van Dam > > > > > ------------------------------------------------------------------------------ > > _______________________________________________ > Jmol-users mailing list > Jmol-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/jmol-users > > -- Robert M. Hanson Larson-Anderson Professor of Chemistry Chair, Department of Chemistry St. Olaf College Northfield, MN http://www.stolaf.edu/people/hansonr If nature does not answer first what we want, it is better to take what answer we get. -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
------------------------------------------------------------------------------
_______________________________________________ Jmol-users mailing list Jmol-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-users