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.
In /misc/ajax.js, line 132, Drupal.ajax does this.url = element_settings.url.replace(/\/nojs(\/|$|\?|&|#)/g, '/ajax$1');
Except in Views js/ajax.js, Drupal.behaviors.viewsAjax only passes the URL in certain cases, causing strange problems.
Comment | File | Size | Author |
---|---|---|---|
#4 | views-1141410-4.patch | 1.25 KB | tim.plunkett |
#3 | views-1141410-3.patch | 1.19 KB | tim.plunkett |
#2 | views-1141410-2.patch | 763 bytes | tim.plunkett |
#1 | views-1141410-1.patch | 368 bytes | tim.plunkett |
Comments
Comment #1
tim.plunkettMy JS is not very good, so I'm not sure that this is the proper way to fix this, but this patch solves the problem.
Comment #2
tim.plunkettI'm seeing this when using FullCalendar, which contains JS links, ones without an href.
This makes more sense now, since it will return unless there is an href that matches 'admin/structure/views', which is the whole point.
Comment #3
tim.plunkettLearning new approaches to control structures. Always cool.
Comment #4
tim.plunkettNow with improved whitespace and a comment!
Comment #5
merlinofchaos CreditAttribution: merlinofchaos commentedLooks good now. Marking RTBC since I'm not in my Views repo right now. we'll see who gets to this first, me or dereine.
Comment #6
dawehnerMakes makes really sense. Commited to 7.x-3.x
Is a backport needed?
Comment #7
dawehnerNo backport is needed.