Home › Forums › Calendar Products › Events Calendar PRO › Disable AJAX pagination for month views.
- This topic has 3 replies, 2 voices, and was last updated 9 years, 6 months ago by Brian.
-
AuthorPosts
-
October 27, 2014 at 8:23 am #840708tw2113Participant
Is it possible to disable loading pagination via when moving between months? We have a case of a user does a search and gets the initial results, and then paginates between months. The browser URL retains all of the $_GET parameters including the search ones, resulting in each month appearing to have the search message above it still. Would love to be able to just do a complete page refresh when clicking for the next/prev month so the $_GET params are cleared out.
October 27, 2014 at 8:52 am #840813BrianKeymasterHi tw2113,
Sure it is possible.
Try this coding out:
https://gist.github.com/jesseeproductions/486ac10c8a7e3b246660
You will have to add that to your theme’s functions.php and comment out the 2nd and 3rd wp_dequeue_script as only the first one is needed to disable ajax on the month view.
Let me know if that works.
Thanks
October 27, 2014 at 11:15 am #841316tw2113ParticipantHi Brian, that did the trick, thanks.
Some feedback, that I am not calling a bug, but perhaps a potentially overlooked detail. Say we have this for a url from a ran search:http://www.domain.com/events/2014-11/?tribe-bar-date=2014-11&tribe-bar-search=Search&tribe-bar-geoloc-lat=33.9835818&tribe-bar-geoloc-lng=-79.15342950000002&tribe-bar-geoloc=Location
. With the month ajax still loaded, clicking the “December” link loads the December view, but since it’s all ajax powered, everything after the ? in the browser url remains. It may be worth considering clearing it all out, if possible and elegant. That way, users wouldn’t need to disable the ajax the way I did.We’re happy and fine to do it however necessary, but it’s some feedback for a future version of the plugin.
October 27, 2014 at 11:54 am #841438BrianKeymasterGlad it works.
I will take a look a the url query string, but I think it is necessary for the search bar to work and do the pagination correctly. I think if we cleared the query string from the url it would break the different views we have, but I will ask around and see if that is possible.
Since the original question has been resolved I am going to close this ticket, but if you need anything else related to this topic or another please post a new topic on the forum and we can help you out.
Thanks
-
AuthorPosts
- The topic ‘Disable AJAX pagination for month views.’ is closed to new replies.