Opened 14 years ago
Closed 10 years ago
#4168 closed bug (wontfix)
Event name collision with mootools
Reported by: | ntoniazzi | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | 1.11.0 |
Component: | ui.slider | Version: | 1.6rc6 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
When integrating jquery+ui (in noConflict mode) with mootools (not a choice), both libraries answer to the "slide" event, and unfortunately, mootools shoots first.
- Mootools: Fx.Slide, "slide" method
- jQuery-ui: ui.slider, "slide" callback
Shouldn't namespaced events prevent this kind of collision? By adding 'ui' or 'jquery-ui' somewhere?
Change History (9)
comment:1 Changed 14 years ago by
Milestone: | 1.7 → 1.8 |
---|
comment:2 Changed 14 years ago by
comment:3 Changed 14 years ago by
A workaround is to remove any previous "slide" method before calling the plugin :
jQuery('div.slider').removeAttr('slide').slider({...});
But it's only a workaround.
comment:4 Changed 12 years ago by
confirming this problem, the workaround resolved the issue for me, thanks
comment:5 Changed 12 years ago by
Until ticket is opened, I've change name 'slide' in lib. Some details in my answer on stackoverflow:
http://stackoverflow.com/questions/4024102/jquery-ui-slider-moving-upwards-and-disappearing-in-the-div-when-used/6778076#6778076
It's work on my joomla 1.6 based site with mootools and jquery-ui enabled
comment:6 Changed 11 years ago by
The workaround in commet 3 by ntoniazzi did not work for me, however I found this answer on stackoverflow with another workaround which worked: http://stackoverflow.com/a/7697597
jQuery('div.slider')[0].slide = null; jQuery('div.slider').slider({...});
comment:7 Changed 10 years ago by
Milestone: | 1.9.0 → 1.11.0 |
---|
comment:8 Changed 10 years ago by
Status: | new → open |
---|
We are planning on switching to firing "widget:event" (for example "slider.slide") to avoid naming collisions with native events.
In the meantime you can switch the prefix the slider plugin uses as a workaround - http://jsfiddle.net/tj_vantoll/4uXbk/.
comment:9 Changed 10 years ago by
Resolution: | → wontfix |
---|---|
Status: | open → closed |
I'm not sure what Mootools is doing, or if this is still a problem, but I'm guessing that this falls into the Object.prototype
-ish bucket.
anyway to fix this?