drupal_add_js(array('vbo' => array('url' => $_GET['q'])), 'setting');
This line in the module adds a variable that overrides the action for the form. The path does not run through the url function so purl does not have a chance to modify the path. Even though the form has the correct url when the VBO startup js runs the action is changed to a broken url.
ex. ( 'site01/content' becomes => 'content')
-Richard
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | Purl_fix_on_group_space-959040-10.patch | 1.14 KB | artkon |
| #10 | Purl_fix_on_group_space-959040-10.patch | 1.88 KB | artkon |
| #6 | 959040-purl_1.patch | 2.31 KB | aron novak |
| #2 | 959040-purl.patch | 1.64 KB | Garrett Albright |
Comments
Comment #1
infojunkieThanks for your report. Tagging for next release.
Comment #2
Garrett Albright commentedPatch!
It looks like this is already in the 6.x-3.x branch, which I accidentally fetched with CVS and tried to patch initially.
Comment #3
infojunkieRe #2: Thanks for the patch. I was somehow thinking of removing the url setting altogether, but if this works for the OP, then great!
Comment #4
aron novakIs it supposed to throw away the query parameters?
For me, it's a bit more robust:
Cause if i'm at a non-ajax views form, it does not throw away my filtering.
Comment #5
Garrett Albright commentedAron, my patch just replicates what's already there. You may be right, though, in that there may be things we're not including in the URL that we should. Would you care to implement your improvement as a patch? If you're new to submitting patches, this page should be helpful.
Comment #6
aron novakPatch is attached.
Comment #7
infojunkieI committed the simpler patch in #2. The patch in #6 broke VBO for installations that are not in the domain root. Anyway, the query parameters are recreated by VBO from the view object directly.
Thanks all!
Comment #9
ryan_courtnage commentedFYI for others who are searching for this:
The patch also fixes a problem where VBO operations will not work when submitted inside of a Space (spaces.module), which uses PURL. Without the patch, submitting a VBO form will result in nothing happening other than the page reloading.
Patch in #2 applies cleanly to 6.x-1.10
Comment #10
artkon commentedJust upgraded to views 3 and bulk operations submit url breaks because its adding the purl of the group twice so http://site.com/g/group_name/node/add/ is wrongfully routed to http://sites.com/g/group_name/g/group_name/node/add/. Solution was to exclude the group's purl if you are in a group space. Patch attached below
Comment #11
artkon commentedPatch updated below.
Comment #12
infojunkie@artkon: please produce a patch against the latest dev. This code has changed a lot.
FYI, the bug you're trying to solve is related to the interaction between Form API, the drupal_goto() core function, and Spaces module. I am willing to include the fix in VBO because I doubt this bug will ever be fixed in D6.
Comment #13
liquidcms commentedjust reporting and subscribing..
not quite sure where this is at but i have Views Bulk Operations (VBO) 6.x-1.11 and Atrium (spaces, og, etc) VBO does not work (seems to work; form is there, lists nodes, etc - just doesn't do anything)
Comment #14
liquidcms commentedhmm.. actually some things work... i could bulk publish posts; but not set node fields (applied patch in #11 as well)
Comment #15
liquidcms commentedbut even without patch above; doing an arb php script as vbo action does work; so perhaps juts a cck issue with modify node fields action?
Comment #16
bojanz commentedYes, probably a separate bug in the modify fields action. You'd need to provide the exact behavior and error for this to be debugged.
Comment #17
bojanz commentedLet's do that in a separate issue. This one has too much history, patches, and unrelated problems.