I made a site for which I don't want any anonymous user to browse, only authenticated, so the anonymous role has no permission at all.
But with these settings, index.php generates a 404:node not found(the log is full of them) page before outputing the login form as a left block and site mission as center block. (tweaked interlaced theme to force site mission there...)
It becomes annoying when a user that have some spyware/malware on his browser gets his 404s to be redirected to a dummy search site. So he never has access to even the login form ! And I have to say to him : "Please clean your browser and then you'll be able to browse my site ". Not very professional !
Could I avoid generating 404 in index.php with anonymous not having access to content.
and maybe, what could I put in the "Default 404 (not found) page:" setting in Administer > configuration
(I don't have clean urls)
Thanks.
Comments
Even a clean, good browser (m
Even a clean, good browser (mozilla firefox) has keywords/automatic redirection to some relevant? page in some cases on by default. For instance if my personal webserver isn't on and I try to access it, I end up in... localhost.be ... great
I have a slightly related problem.
My custom-made 404 is quite popular on my site and it shows up on the statistics, on the top 10 etc which I don't want.
I think I saw a node here concerning this but I can't seem to find it anymore...
so ok let's resume
The fact is that there are too many 404 generated by drupal on the beginning page, especially when you don't want to show content to anonymous users.
404 should be avoided, but only on the starting/login page, not "inside" the system.
the "rubberband-on-a-wood-leg" solution I found for the moment is simply to substitute the drupal_not_found() function in index.php by just the last part of its own code. ...