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 have the latest -dev version and the page title in the confirmation step is NOT changed according to the operation (see screenshot).
View export attached.
The confirmation message works ONLY on pages (views) provided by admin_views module.
Thank you in advance for help.
Comment | File | Size | Author |
---|---|---|---|
#5 | views_bulk_operations-conf_form_title-2173259-5.patch | 2.21 KB | Garrett Albright |
#1 | 2143259-1-confirm-title-clobbered.patch | 1.28 KB | Garrett Albright |
test_vbo.txt | 7.99 KB | my-family | |
Screenshot - 14.1.2014 - 14:04:26.png | 29.48 KB | my-family |
Comments
Comment #1
Garrett Albright CreditAttribution: Garrett Albright commentedThis seems to have worked at one time, but currently does not. The page title is set to the question when VBO calls confirm_form(), but then Views itself clobbers it with the View title.
Here's a workaround where we change the title of the View so that Views just clobbers the desired title with the desired title again.
Comment #2
Garrett Albright CreditAttribution: Garrett Albright commentedSo my patch only works if you reload the page that the confirmation form is on. The *first* time that page loads, it still shows the View's title. I have no freakin' clue what's going on there; tracing through the code, I can't see where the title is getting reset between where I set it and where the title is retrieved again.
I also tried
…but it's the same result.
This is a very strange bug.
Comment #3
Garrett Albright CreditAttribution: Garrett Albright commentedI've checked out tags throughout the 7.x-3.x branches of both VBO and Views, and couldn't find a spot where this wasn't happening. Apparently this is a pretty long-running problem… Is there some other issue I couldn't find which has a lot more comments in it, or do people really not care that much about it?
In my case, the client needs it, so… I'm back at it.
Comment #4
bojanz CreditAttribution: bojanz commentedI don't think anyone pays attention, this is the first time I've seen an issue about it.
That said, I'm pretty sure it worked when I first wrote it (back in 2011).
But the title / breadcrumb handling of views / core fluctuated multiple times since then.
Comment #5
Garrett Albright CreditAttribution: Garrett Albright commentedWell, that's surprising.
It looks like any changes we try to make to the View in the form callback function don't "stick;" I guess because they're operating on copies of the View. Though why they'll then work just fine if you reload the confirmation form page… iz mystry. I got similar results why trying to set the title in theme_views_bulk_operations_confirmation(). I was hoping to avoid just implementing hook_preprocess_views_view(), but that seemed to be the only way I could find to get it working… =/
Comment #6
bojanz CreditAttribution: bojanz commentedCommitted, thanks.
Comment #8
marcusx CreditAttribution: marcusx commentedThis change has broken all my views titles.
I get either no title at all (for new views) or "<" = "&lgt" for existing views.
Comment #9
lmeurs CreditAttribution: lmeurs commented@marcusx: Since this patch has been committed I created a new issue #2312547: Broken view titles, they often only display a < character and will set the status of this one back to fixed.