Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 293522

views_exposed_form_cache() flaw, eg. leads to exposed forms redirecting to frontpage

$
0
0

views_exposed_form_cache() has some flaws
* it does not respect $form_state['no_cache'] - OK, this can be easily fixed
* it does not have a reset parameter - no problem per se but this makes userland workarounds for problem below impossible
* it caches by view&display-name which was a good idea when we only had views pages and blocks, but now with panels glory is not appropriate anymore - see example below

example which hit me:
1) create a views panel pane display
2) query it programatically and display the result count
3) show it as panels pane

result:
* in 2) $view->override_path is empty and gets stored in cached exposed form
* in 3) $view->override_path is panel path, but exposed form is taken from request cache
* so every exposed form submission redirects to frontpage

This problem generalizes when a view pane is used more than once in a request.


Viewing all articles
Browse latest Browse all 293522

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>