Posted by colincalnan on July 12, 2010 at 10:45pm
6 followers
Jump to:
| Project: | Views Hacks |
| Version: | 6.x-1.x-dev |
| Component: | Views Filters Auto-submit |
| Category: | bug report |
| Priority: | normal |
| Assigned: | colincalnan |
| Status: | closed (fixed) |
Issue Summary
I used this module combined with the Better Exposed Filters module to turn multiple selects into checkboxes.
When I tested in IE it wasn't working. I had a look at the JS file at views_hacks/views_filters_autosubmit/views_filters_autosubmit.js and found that the form was submitting on the change() event for the form elements.
change() does not work on checkboxes - http://api.jquery.com/change/
The change event is sent to an element when its value changes. This event is limited to elements, boxes and elements.
So I had to modify this file and use bind('click change') to cover both scenarios.
Attached is a patch
| Attachment | Size |
|---|---|
| views_hacks-views_filters_autosubmit.patch | 943 bytes |
Comments
#1
Your patch causes select filters to auto-submit when they are clicked, which is not desired. Furthermore, the documentation that you point to explicitly mentions checkboxes as being supported:
So what's needed is a patch for IE specifically, if any.
#2
Subscribing.
#3
Had the same problem with radio buttons in IE.
Just added
$('div.views-exposed-widget .form-radios input'+exceptions, self).click(function() {$(self).submit();
});
And it's working fine now.
#4
I'm using Better Exposed Filters too and I have the same issue in IE.
A short solution is to fireing CLICK event instead of CHANGE only in input (NOT SELECT!!!) elements.
In your views_filters_autosubmit.js (6.x-1.0-beta1) simply change this code:
$('div.views-exposed-widget input'+exceptions, self).change(function() {$(self).submit();
});
$('div.views-exposed-widget select'+exceptions, self).change(function() {
$(self).submit();
});
With this:
$('div.views-exposed-widget input'+exceptions, self).click(function() {$(self).submit();
});
$('div.views-exposed-widget select'+exceptions, self).change(function() {
$(self).submit();
});
#5
#6
I committed a fix in the latest release. Please test (12 hours from now for the dev release to refresh or by pulling from CVS DRUPAL-6--1 directly) and let me know!
#7
Automatically closed -- issue fixed for 2 weeks with no activity.