Jibap and /users
in the path get a 404 error.
There is no such thing as /users
path, and this isn't stated anywhere. Files Gallery doesn't and can't create paths by itself. Besides, what would the /users
path do anyway? All users, login or non-login, will always access your gallery from the same path where you installed Files Gallery. If you want to force login, just append ?login=1
in the url.
PS! Maybe you were confused by the users demo at demo.files.gallery/users? The /users
path is just where I have placed our users demo (separate from the main demo). The path /users
isn't part of the application in any way.
Jibap i have no user/pwd in basic config.php : the login icon is not shown
And you have created other users? This missing login button is a bug, which will be resolved in next release coming shortly. For now, if you don't see the login button, you can access login by appending ?login=1
to your url.
Jibap i add a user/pwd : the login form is shown and i have the logout icon
i remove user/pwd : the login icon is shown in header and i can connect with another user
i delete the current cookie for the page, the login icon disappears !
I will take a look into this, thanks for reporting. Even if the login button displays by some bug/mistake, if there are no valid users, then the login page would not even display, and login certainly wouldn't be possible. I will look into it shortly, currently away, back in office on Wednesday.
Jibap Other thing, i think your config way is not intuitive, i explain why : if you use Gallery to share folders to distinct users
What do you mean "share folder to distinct users" though? Files Gallery is not a file sharing app, it does not use a database, and it can't create special links to "share" folder to distinct users. Therefore, I can't respond to your claim that the config is not intuitive. If you need to use a real file sharing app, you will need to use NextCloud or FileRun, massive apps that will control your file system and use database.
Jibap If you set your admin user in basic config.php file
Why would you do that though? Why create the main "admin" user in the "public" config.php? You would do that if you only ever have one single user (admin user). Otherwise, the default config.php should either be 1. non-protected (which would be the case if you want public view, with admin users(s)), or 2. the password-protected public user with minimal permissions. Or why not just create all your users separately for best and most logic control? The main config.php can either be protected or not, but it's still the main config, from which all other users inherit their settings, unless overridden. Surely the logic is that this is default config, with least permissions, and then all your USERS can override these settings and permissions. It should make sense.
Jibap If you set your admin user in basic config.php file, you set privileges for you but you have to set for each users restrictions, not really practical... I know that you added the "allow_all" new param to avoid this but it is all or nothing.
Surely it would make sense to NOT do it like that. Users should be assigned with permissions that override default config.php. Default should be public, or users with the least permissions (or no permissions at all). It's not that difficult to do it this way.
Jibap So, i did that : my basic config.php file has no rights (only langage, licence key, maybe hidden files exclude...), only what is similar to all users, and i create distinct users with their own permissions and my admin user is one of them.
Yes please. That is of course the best logic. Then you just assign any special permissions on a per-user basis.
Jibap if you have no public access, you need to set a fake user in basic config.php with unfindable username/pwd... maybe a simple boolean settings like "public_access=false" may be better, no ?
Default config is considered default user, so you could just use it for any of your users, but it should then be the user with least permissions. Or if this is confusing, and you don't want public login, you could of course just create a complex password for default config. I agree this is not optimal, but it's not too complicated either.
Jibap maybe a simple boolean settings like "public_access=false" may be better, no ?
I was considering this, but it seems to cause more confusion than it helps. Ultimately, the username and password in default "public" config decides if the gallery requires login or not (essentially like it was before I created users). New users just allows new login-users, regardless of if the default config is login- or not.
Thanks for sharing! There will be a new version with Settings + Users editor within two weeks time.