In views_data_export/plugins/views_data_export_plugin_display_export.inc, we have this line of code:
$return_path = empty($_GET['return-url']) ? '' : $_GET['return-url'];
I tried adding "?return-url" to the end of the Data Export display path, but the URL on the results page winds up being:
http://www.company.org/memberexport/user_export.csv%3Freturn-url%3Dmemberexport?eid=7
Obviously I'm not adding the return-url properly. How am I supposed to set a return-url?
If I rework the URL to be this:
http://www.company.org/memberexport/user_export.csv?eid=7&return-url=memberexport
It works great.
Thanks.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | allow_return-url_parameter-1860376-4.patch | 1.06 KB | dobe |
Comments
Comment #1
dpearcefl commentedNo answers on how to use this parameter?
Comment #2
dpearcefl commentedBump one last time. Really would like an answer. Thanks.
Comment #3
steven jones commentedSorry but the return URL parameter is really for internal use, and not for you to choose where the export redirects to at the end of the process, sorry!
Comment #4
dobe commentedIt would be nice if this functionality were in place. I have a view that displays a list of link's to different views that have csv exports that I would like to return to after. Attached is a simple patch to allow this to happen it should not really be a big issue as it seems the main use of this return url is just to provide a link back to wherever you came from.
-Jesse
Comment #5
R.Hendel commentedThanks for your work, Jesse!
I tested it and everything works as expected:
While testing in our project
There is one problem remaining, but this may be caused by some other things:
We use views_data_export attached to a content pane using panels.
When I trying batch mode, than it breaks in that sense, that module behaves like unpatched version.
Comment #6
dobe commentedHmm. As long as you pass the return-url to the url it should override any default functionality. In your instance are you passing the return-url or are you trying to use the views functionality "Attach to:"? If you are, is it a "Content pane" your trying to attach it to? I would need some further information to debug your issue.
-Jesse
Comment #9
nwom commentedThis appears to have been included in the module. In the newest dev release, the functionality is in place.