Page 1 of 1

Problem with allowing download for a specific user group

Posted: 01 Dec 2013, 18:19
by szablac
Hi,

I have some files on my site which can be accessed only by a specific user group, but I want to display those inaccessible files to everyone. When a visitor click to download the file, he gets the message 'Please login to download the file'. That is great.
Then this visitor logs in. He is only a Registered user, but not a member of that specific user group. He still don't access the file (that's great), but he gets the message 'Please login to download the file' again, although he has already logged in.
This second message should be 'You do not have rights to access the file' or 'You are not member of the group that can access the file' or something similar. Additionally, the user should be redirected back to category view, when he gets the new warning message.
Does anyone else bumped into this issue?

Re: Problem with allowing download for a specific user group

Posted: 01 Dec 2013, 22:30
by Jan
Hi, yes for now there is no difference between both messages. So this needs to be customized in the code. For now you get the messages in case you are not able to download the files - but from the system you only get one information - not access - so you can change the message in language file - e.g. add there some common info - you need to login and you need to be a part of the right group. :idea:

To do it exactly for your needs, some large modification needs to be done - when the user cannot access the file - then the system needs to get information about if user is logged it or not - if he/she is not logged it - then he/she gets other message than someone who is logged in. :idea:

Jan

Re: Problem with allowing download for a specific user group

Posted: 02 Dec 2013, 11:11
by szablac
Thank you for your answer, Jan.
For now I took your advice. I made a language override - not in the file, but in Language Manager. Additionally I added some explanation to the description of the category.
I hope sometime you will have time and intention to make those large modifications. :wink:
Thanks for the great component!