[Resolved] Gridview date selectors
Hi There ModernTribe!
I just found a bit of a bug when using this plugin with the Uniform JS library (Uniformjs.com). It adds wrappers around any form elements, and messes up your datepicker dropdown script. Instead of returning “http://example.com/events/2012-10” it returns “http://example.com/events/undefined2012-10”.
On line 50 of the events.js file, there’s a line that looks like this:
baseUrl = $(this).parent().attr("action");
Because Uniform.js wraps inputs and selectors in divs (so it can replace them with pretty-looking spans), the ‘parent’ of doesn’t have an ‘action’ when this happens. A solution to this is to replace that line with this:
baseUrl = $(this).closest('form').attr("action");
Hope this helps someone else!
- The topic ‘[Resolved] Gridview date selectors’ is closed to new replies.