Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I am using bootstrap theme and on scroll I'm getting this error for super admin.
Failed to load resource: the server responded with a status of 403 (Forbidden)
Uncaught Drupal.AjaxError
Comments
Comment #2
tsi CreditAttribution: tsi as a volunteer commented7 months and not a single comment?
Same happens to me. in a custom theme (
base theme: classy
).Did you find the cause?
Comment #3
tsi CreditAttribution: tsi as a volunteer commentedIn my case it was the view access-argument that was killing my ajax calls, seems like a bug, but in my case I could just remove it.
Comment #4
caspervoogt CreditAttribution: caspervoogt commentedI just updated to 8.3.7 and now this started happening to me, too;
Failed to load resource: the server responded with a status of 403 (Forbidden) views/ajax?_wrapper_format=drupal_ajax
I don't know yet why this is happening. Views access argument is the default "view published content" so that should be fine. I am also logged as superadmin, but it should not make a difference.
Comment #5
dabbor CreditAttribution: dabbor at Morpht commentedI had the same problem and after I updated the
views_infinite_scroll
module to1.5.0
version the problem was gone, but a new one arised: After I click the "Load More" button, the page is reloaded with the next page content (according to pager).Comment #6
ericpughI'm having the same issue as described in #5, using 1.5 and Drupal 8.3.7, where the "Load More" button causes a page reload. This may have something to do with the security views/ajax changes made in 8.3.7 and might be related to #2902831: Entity browser views that do not have use_ajax explicitly enabled are broken with 8.3.7
Comment #7
dabbor CreditAttribution: dabbor at Morpht commentedWe found out that the problem was caused by missing
docroot/core/modules/views/js/ajax_view.js
file as it wasn't loaded due the option Use AJAX being switched off.It wasn't required before to have the option "Use AJAX" enabled before in order to make the Views Infinite Scroll work, but after the View's update it is needed. Probably it is the way it should work and previous behavior was just a bug.
Comment #8
smazThis may be related to the recent core update:
https://www.drupal.org/SA-CORE-2017-004
Comment #9
Alex Bukach CreditAttribution: Alex Bukach commented@dabbor thanks for #7, you saved my day!
Comment #10
drupalfan2 CreditAttribution: drupalfan2 as a volunteer commentedI updated drupal core from 8.3.6 to 8.3.7 and now the Load more button from "views infinite scroll" does not work anymore:
Views Infinite Scroll 8.x-1.3 -> a lot of error messages in chrome console.
Views Infinite Scroll 8.x-1.5 -> Load more button does nothing!!!
Can you tell me how to solve this (maybe some solution above helps, but which?). Thank you.
Comment #11
smaz@drupalfan2, if you ensure that the view is set to use ajax, under the advanced options on the right hand side, that should work.
Comment #12
drupalfan2 CreditAttribution: drupalfan2 as a volunteer commentedThank you very much.
This seems to work for both versions of Views Infinite Scroll.
Comment #13
caspervoogt CreditAttribution: caspervoogt commented@dabbor for #7, thank you! I had updated, and my scroller stopped working. This solved it for me.
Comment #14
dalinIn my case even though when I edit the view it said:
> Use AJAX:Yes (Forced)
it apparently wasn't happening. When I edited the AJAX settings, saved the setting, and saved the view, then everything started working again.
Comment #15
Kleve CreditAttribution: Kleve at Happiness commentedProposed solution to manually enable AJAX in the view does not work for me. No error messages displayed. Any ideas or anyone else experiencing this?
Setup
Drupal 8.3.7
Views infinite scroll 8.x-1.5
Update: The problem occures when placing the the view block within a paragraph. As a regular view block placed from the block page, everything works as expected.
Comment #16
andrew_hoffi CreditAttribution: andrew_hoffi commentedI've also noticed that Ajax is failing, but I believe this is because of a conflict with either Better Exposed Filters or Masonary.js
Comment #17
staceroni CreditAttribution: staceroni commentedI followed the resave ajax suggestion.
I exported the configuration and compared the view that was having the issue.
use_ajax: true was added to configuration upon saving the ajax settings.
I am no longer getting the 403 ajax error.
Comment #18
owntheweb CreditAttribution: owntheweb commented@dabbor #7: YES. My day is better now. Thanks!
Comment #19
XerraX CreditAttribution: XerraX commentedhappend to me too after updating drupal...
Comment #20
handkerchiefin my case, when I click on the button, the button disappears and nothing else happens, no javascript error.
Drupal 8.4.0
Views Infinite Scroll: 8.x-1.5+1-dev
Comment #21
cola CreditAttribution: cola commentedAfter drupal update same issue
Comment #22
FlutterStack CreditAttribution: FlutterStack commentedComment #23
FlutterStack CreditAttribution: FlutterStack commented@dabbor #7: worked for me. Thanks!
Comment #24
Keith Caulkins CreditAttribution: Keith Caulkins commented@dabbor Thank you! Comments #5 and #7 helped me a ton!
Comment #25
inversed CreditAttribution: inversed commentedI was able to work around this issue by setting the View to use AJAX for "All" displays and then turning AJAX off for any Views displays that didn't need it.
I noticed that in some versions of Drupal, the displays that used Infinite Scroll had their AJAX option set to "Yes (Forced)" which wasn't working correctly.
Comment #26
Neslee Canil Pinto