You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
var pjax = new Pjax({
elements: "#search-form",
selectors: [".search-results"]
});
Now within my form I have an hidden input field. I have a dropdown outside of the form which can set the value of this hidden input dynamically. So for example I have:
$('#sort-by').change(function() {
var value = $(this).val();
$('#sort-by-value').val(value);
$('#search-form').submit();
});
As you can see, I am submitting the form when the dropdown value changes, but this results in a non-pjax request. How can I make it trigger the pjax request when I submit the form via JS?
The text was updated successfully, but these errors were encountered:
I have activated pjax on a form as follows:
Now within my form I have an hidden input field. I have a dropdown outside of the form which can set the value of this hidden input dynamically. So for example I have:
JS:
As you can see, I am submitting the form when the dropdown value changes, but this results in a non-pjax request. How can I make it trigger the pjax request when I submit the form via JS?
The text was updated successfully, but these errors were encountered: