Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix "not authorized" messages due to client mismatch in upload file #470

Closed
wants to merge 1 commit into from
Closed

Conversation

klas
Copy link
Collaborator

@klas klas commented Nov 3, 2017

When user is previewing uploaded file from form default content client is being used as it is missing in the link, resulting in non-authorized messages if field is not also added to the content tab of the type.

https://www.seblod.com/community/forums/fields-plug-ins/you-are-not-allowed-to-access-this-file#post55714
https://www.seblod.com/community/forums/fields-plug-ins/upload-file-755-permissions#post55729

When user is previewing uploaded file from form default content client is being used as it is missing in the link, resulting in non-authorized messages if field is not also added to the content tab of the type.

https://www.seblod.com/community/forums/fields-plug-ins/you-are-not-allowed-to-access-this-file#post55714
https://www.seblod.com/community/forums/fields-plug-ins/upload-file-755-permissions#post55729
@joomleb
Copy link

joomleb commented Mar 27, 2018

Hi Klas,
seem the "permission" issue is been solved, but it's running as "Download", while should work as "Preview" in a new window, as well as has been translated from Seblod team.
As Bes wrote here:

The download.php script is used to download...
To not download a PDF file but to open it into the web navigator, it's just to display a link to the physical PDF file. A typo plugin apply on value of file field can be a solution.
Of course, this usage is only for PUBLIC PDF file. By doing this there no ACL control of the file (done by the download.php script).
Here we are speaking about the Upload script, that by default from Seblod team show an icon link as "Preview", preview in a new window not download, or should be wrote "click to download" (at least this is what has been translated from Seblod team).

So the link shown after an upload by the Upload field, as far as I understand, is a "download link".
Considering that, when I upload a pdf, a checkbox is shown in case I want delete the file and upload a new one, Here should be tranformed by deafault:

  • like a "A typo plugin apply on value of file field can be a solution"
  • shown to the owner and hidden for all others users ("there no ACL control of the file (done by the download.php script)"

@sebastienheraud sebastienheraud added this to the SEBLOD 3.16.0+ milestone Jun 18, 2018
@klas klas closed this Sep 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants