Closed (outdated)
Project:
Drupal core
Version:
9.4.x-dev
Component:
user system
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
21 Jan 2007 at 06:46 UTC
Updated:
9 Oct 2023 at 17:32 UTC
Jump to comment: Most recent
Comments
Comment #1
jjeff commented+1 on this. The only possible problem is that the user may still be denied upon log in. Also, if a sidebar login block is displayed, the page can end up with two login/password fields being displayed.
That being said, I don't think there are any reasons this couldn't be a site setting. This may be the easiest one to implement of this group of Logintoboggan-to-core issues.
Comment #2
birdmanx35 commentedWell, one of my pre-Drupal design rules was:
Redundancy is good!
Comment #3
pasqualleComment #4
cafuego commentedMoved to 8.x. Is it really necessary to move this functionality into core, rather than simply use logintoboggan?
Comment #5
spidersilk commentedI would love to have it in core. LoginToboggan alters the login system in a variety of ways, and not every site may want all of them. Also, the more additional modules are enabled for a given site, the more memory is needed, so if all someone wants is the user login block to be able to show up on 403 error pages, it would be nice not to have to install a contrib module that also does a dozen other things you don't want or need.
Comment #6
matt.rad commentedI agree with #5. I have used Logintoboggan in the past and it created more problems than it solved, being incompatible with a bunch of other things I wanted during login. Besides, having to install that whole module just to achieve this one, simple thing (that IMHO should be part of the core UX anyway) seems like overkill.
For now, using Redirect 403 to User Login https://www.drupal.org/project/r4032login
Comment #11
dqdAdditionally to the fact that this issue is quite old and maybe obsolete, I would like to point to the option in core to use 403 redirect settings in
admin/config/system/site-informationto redirect to the user/login path for any who humbles over this issue here. The only drawback covered here #2916746: Redirect subrequest via Basic site settings do not incoorporate correct theme rendering, suggestions and overrides for target path. : ...It sadly makes the login page unstylable from top (like commonly used by many themes), since the redirect does not add the common login-form class to the HTML body tag.
Comment #14
redzeufFor Drupal 8 there is differents solutions depends on your needed behaviour.
You can go to admin/config/system/site-information and set "Default 403 (access denied) page" to "/user/login"
You can use the module Anonymous Login
Action to do for the review
The issue is very old I think it's a good idea to decide to postpone if we have the intention to include it in the core otherwise to Closed it as outdated and keep it like this.
It seems not to have a lot of people declaring here that they want the feature in the core. I think it's a good idea to include this feature in the core because the majority of Drupal websites today have authenticated pages.
Comment #15
phjouThe core already provides a Login Block. Why not implementing a Block Condition based on the HTTP Response Code? Then you can place your block based on that code.
I have found a module that seems to do that but I have not tested it: http_client_error_status
Comment #21
gagarine commentedThis issue is outdated. At this point it's certainly better to close it and opening a new one if necessary.
Two custom modules that do the job:
You can do your own custom module following: https://www.getlucius.com/en/blog/drupal/drupal-how-redirect-anonymous-u...
Comment #22
nessunluogo commented1 year after followup, but I think this can help the community.
Another nice solution I suggest is using the HTTP Client Error Status Block Condition module with the default Login block, a contributed alternative or a custom one.
Just place the block in a region of your choice and select the 403 (forbidden) HTTP status in the visibility tabs.
It's D10 compatible, pretty easy to use and very versatile. Plus you don't need to redirect that is more coherent with the OP and the D7 Logintoboggan feature.
While writing I missed the phjou comment #15 about the same module.