What would be the general answer for modules which use jquery with Drupal 6. Do modules need the dependency on jquery_update module?

these are 2 issues with 2 different answers for the same question:
#283968: jQuery Update not needed
#330998: Remove jquery_update dependency from D6 version

Comments

pasqualle’s picture

and please display the answer on the module's project page.

mfer’s picture

The answer to this question is different for both drupal 5 and 6. I'll attempt to make it clearer for drupal 6.

The answer is, it depends. jQuery Update provides the most recent version of jQuery for sites to use. At the moment core is running the most recent version of jQuery so most modules should not need the dependency. If/when a newer version of jQuery comes out and a module needs to take advantage of some of the newer jQuery version features it would need it.

Many modules had previously needed the dependency (for example, when drupal core was running jQuery 1.2.3) but may no longer need it. It might be there for legacy reasons.

The jQuery UI module is different. It not only takes advantage of the newest version of jQuery, it uses the same preference settings.

Does this make more sense? What modules are requiring the dependency that you are curious about?

pasqualle’s picture

I don't have a specific module, I just wanted to have one answer (same solutions) for Drupal 6 modules..

mfer’s picture

Status: Active » Fixed

I think I can answer this one now. If your module needs a version of jQuery newer than 1.2.6 you'll need this modules as a dependancy.

pasqualle’s picture

Is there a D6 core issue or any documentation about that D6 will not contain jQuery newer than 1.2.6?

mfer’s picture

As a rule, drupal does not update major versions of libraries in minor version updates of drupal. Updating to jQuery 1.3.x in drupal 6 core would break a lot of contrib modules.

I can't point you to the issue off hand where this is documented but, I know it is that case and have read the issues that state this. The major version of jQuery Drupal 7 releases with will be the version it will always ship with. The major version of jQuery drupal 5 shipped with is still the version you get with it. This is done for compatibility. It would change the api to ship with a different version and that will break contrib modules.

That is why this module exists. For those who are comfortable upgrading to a newer version of jQuery and dealing with the consequences. In drupal 7 we've made it even easier for a contrib module (like this one) to alter JavaScript files.

pasqualle’s picture

yes, that sounds reasonable.
Thank you Matt for the explanation.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.