Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Comment | File | Size | Author |
---|---|---|---|
#7 | jquery-life-fix-2476447-7.patch | 1.37 KB | rlangille |
#6 | jquery-life-fix-2476447-6.patch | 1.38 KB | rlangille |
#4 | jquery-live-fix.patch | 1.46 KB | asherry |
Comments
Comment #1
GabberMan CreditAttribution: GabberMan commentedI had the same problem.
For solve it, go to sites->all->modules->calendar->js and modify the file calendar_colorpicker.js at line 13:
Before:
$(".edit-calendar-colorpicker").live("focus", function(event) {
After
$(".edit-calendar-colorpicker").on("focus", function(event) {
The method live is deprecated in jQuery 1.7
Comment #2
filnug CreditAttribution: filnug commentedThank you GabberMan.
#1 worked for me.
it should be commit!
Comment #3
asherry CreditAttribution: asherry commentedThat's not going to be a viable fix, .live() was deprecated in favor of .on() in version 1.7 but .on() was only added in version 1.7. This fix will break if the jQuery version is then lower then 1.7, which it will be by default.
I've added a comparison in this patch to make sure it doesn't break with older versions.
I've reduced this priority to Normal as well as it's only a problem with jquery versions higher than 1.7.
Comment #4
asherry CreditAttribution: asherry commentedAdded patch.
Comment #5
jmuzz CreditAttribution: jmuzz commentedThis fixed the issue for me.
Comment #6
rlangille CreditAttribution: rlangille commentedThis is becoming more of an issue now that web application scans are picking up versions of jQuery lower than 1.12.2 as being vulnerable. More sites will be using jQuery update and jQuery Migrate soon. I'd recommend testing and fixing this soon for PCI compliance reasons.
Here's an updated patch with the same basic approach, but that's closer to what's already there, has a simpler comparison function, and a better named focus function.
+1 for cross version compatiblity!
Comment #7
rlangille CreditAttribution: rlangille commentedCopy paste mistake when changing function name. Fixing patch.
Comment #8
alasda CreditAttribution: alasda commentedReviewed and tested patch #7. Appears to work as expected.
Comment #9
wylbur CreditAttribution: wylbur commentedComment #11
Neslee Canil PintoCommitted, Thanks.