Skip to content

Redirect attachment download to view if accessed from external link #8976

@garethrees

Description

@garethrees

Some articles, reports, etc link directly to the attachment "download" URL rather than the "view" URL.

Since #8916, this means that when you click on one of these links, instead of being taken to example.com/request/foo/response/1234/attach/1/information.pdf, the file just downloads without the visitor ending up on an Alaveteli site URL.

This is annoying as:

  1. They probably weren't expecting clicking a link to initiate a file download
  2. It's difficult to get back to the request page. Before, you'd just delete /response/1234/attach/1/information.pdf from the URL; now you've got to copy the URL to the clipboard, paste it somewhere and then do the deletion.
  3. It reduces the promotion of the site – people clicking the link are less likely to see the domain name and get curious about how ATI was used to get the information.

What would be ideal is if a "download" URL is visited from an external site, we redirect to the "view" URL for that attachment (if available).

Metadata

Metadata

Assignees

No one assigned

    Labels

    f:request-analysisimprovementImproves existing functionality (UI tweaks, refactoring, performance, etc)x:uk

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions