You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Gare <ga...@wanadoo.es> on 2004/12/13 17:49:04 UTC
[users@httpd] ErrorDocument 403 and so doe'nt redirect properly
My problem is that ErrorDocument doesn't redirect to the page I've configure in httpd.conf if I don't use a absolute URL.
My Apache server manage several virtual hosts, I have error page 404 redirect to /error/404.htm. That's in the main section of httpd.conf I wrote:
ErrorDocument 400 /error/400.htm
ErrorDocument 401 /error/401.htm
ErrorDocument 402 /error/402.htm
ErrorDocument 403 /error/403.htm
ErrorDocument 404 /error/404.htm
ErrorDocument 500 /error/500.htm
Error 404 (page not faound) works right, but 403 or 500 go to defaul pages. But if I put
ErrorDocument 403 http://mydomain.com/error/403.htm
then page 403 is redirected to the correct page.
I've tried to write the ErrorDocument configuration sentences inside virtual host directive, but the problem is the same.
(Apache 1.3.3)
Any idea of where is my mistake?
Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
Posted by "Ivan Barrera A." <Br...@Ivn.cl>.
If using microdull explorer, try disabling "friendly error messages" or
similar..
Joshua Slive wrote:
> On Mon, 13 Dec 2004 17:49:04 +0100, Gare <ga...@wanadoo.es> wrote:
>
>>
>>My problem is that ErrorDocument doesn't redirect to the page I've configure
>>in httpd.conf if I don't use a absolute URL.
>
>
> Have you tried a non-Microsoft browser?
>
> MSIE will ignore server-supplied error pages if they are "too small".
>
> Joshua.
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
Posted by Joshua Slive <js...@gmail.com>.
On Mon, 13 Dec 2004 17:49:04 +0100, Gare <ga...@wanadoo.es> wrote:
>
> My problem is that ErrorDocument doesn't redirect to the page I've configure
> in httpd.conf if I don't use a absolute URL.
Have you tried a non-Microsoft browser?
MSIE will ignore server-supplied error pages if they are "too small".
Joshua.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] Re: ErrorDocument 403 and so doe'nt redirect properly
Posted by Joshua Slive <js...@gmail.com>.
On Mon, 13 Dec 2004 18:58:37 +0100, Michelle Konzack
<li...@freenet.de> wrote:
> AFAIK must it be the FULL path to the error files
>
> /error/XXX.html
>
> mean your filesystem.
No. The docs say ErrorDocument take a URL-path.
Joshua.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
[users@httpd] Re: ErrorDocument 403 and so doe'nt redirect properly
Posted by Michelle Konzack <li...@freenet.de>.
Hello Gare,
Am 2004-12-13 17:49:04, schrieb Gare:
> My problem is that ErrorDocument doesn't redirect to the page I've
> configure in httpd.conf if I don't use a absolute URL.
> My Apache server manage several virtual hosts, I have error page 404
> redirect to /error/404.htm. That's in the main section of httpd.conf
> I wrote:
> ErrorDocument 400 /error/400.htm
> ErrorDocument 401 /error/401.htm
> ErrorDocument 402 /error/402.htm
> ErrorDocument 403 /error/403.htm
> ErrorDocument 404 /error/404.htm
> ErrorDocument 500 /error/500.htm
AFAIK must it be the FULL path to the error files
/error/XXX.html
mean your filesystem.
> Any idea of where is my mistake?
Greetings
Michelle
--
Linux-User #280138 with the Linux Counter, http://counter.li.org/
Michelle Konzack Apt. 917 ICQ #328449886
50, rue de Soultz MSM LinuxMichi
0033/3/88452356 67100 Strasbourg/France IRC #Debian (irc.icq.com)
Re: [users@httpd] ErrorDocument 403 and so doesn't redirect properly
Posted by Gare <ga...@wanadoo.es>.
FIXED: 403 redirect properly, and so 500, 406, and so on!!!!
Really: if error pages are not too small the document error functions
properly.
Thanks you all.
----- Original Message -----
From: "Ivan Barrera A." <Br...@Ivn.cl>
To: <us...@httpd.apache.org>
Sent: Wednesday, December 15, 2004 3:16 AM
Subject: Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
> Dont know if another person replied this but, i remember having trouble
> when my error pages where less than 1kb in size.
>
> Gare wrote:
> > No, 404 error are managed ok by apache, vhosts use the config of the
main
> > (common) configuration. Malfunction appears in 403, 500 and others
document
> > errors. And more, the problem too appears if document errors are
> > configurated inside vhosts section
> >
> > regards
> >
> > ----- Original Message -----
> > From: "Ralf Glauberman" <rg...@michaeli-gymnasium.de>
> > To: <us...@httpd.apache.org>
> > Sent: Monday, December 13, 2004 10:49 PM
> > Subject: Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect
properly
> >
> >
> >
> >>hi,
> >>just one idea, but is it for sure that apache will be able to know which
> >>vhost is active in an error-condition? i think it could be possible that
> >>apache wants absolute pathes here because it isn't sure if it will
always
> >
> > be
> >
> >>able to know the right vhost. correct me, if i'm wrong.
> >>ralf
> >>
> >>----- Original Message -----
> >>From: Gare
> >>To: users@httpd.apache.org
> >>Sent: Monday, December 13, 2004 5:49 PM
> >>Subject: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
> >>
> >>
> >>My problem is that ErrorDocument doesn't redirect to the page I've
> >
> > configure
> >
> >>in httpd.conf if I don't use a absolute URL.
> >>My Apache server manage several virtual hosts, I have error page 404
> >>redirect to /error/404.htm. That's in the main section of httpd.conf I
> >>wrote:
> >>ErrorDocument 400 /error/400.htm
> >>ErrorDocument 401 /error/401.htm
> >>ErrorDocument 402 /error/402.htm
> >>ErrorDocument 403 /error/403.htm
> >>ErrorDocument 404 /error/404.htm
> >>ErrorDocument 500 /error/500.htm
> >>
> >>Error 404 (page not faound) works right, but 403 or 500 go to defaul
> >
> > pages.
> >
> >>But if I put
> >>ErrorDocument 403 http://mydomain.com/error/403.htm
> >>
> >>then page 403 is redirected to the correct page.
> >>
> >>I've tried to write the ErrorDocument configuration sentences inside
> >
> > virtual
> >
> >>host directive, but the problem is the same.
> >>(Apache 1.3.3)
> >>
> >>Any idea of where is my mistake?
> >>
> >>
> >>---------------------------------------------------------------------
> >>The official User-To-User support forum of the Apache HTTP Server
Project.
> >>See <URL:http://httpd.apache.org/userslist.html> for more info.
> >>To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> >> " from the digest: users-digest-unsubscribe@httpd.apache.org
> >>For additional commands, e-mail: users-help@httpd.apache.org
> >>
> >>
> >
> >
> >
> >
> > ---------------------------------------------------------------------
> > The official User-To-User support forum of the Apache HTTP Server
Project.
> > See <URL:http://httpd.apache.org/userslist.html> for more info.
> > To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> > " from the digest: users-digest-unsubscribe@httpd.apache.org
> > For additional commands, e-mail: users-help@httpd.apache.org
> >
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
Posted by Fen Lu <go...@gmail.com>.
I tried like this:
ErrorDocument 404 "/error/test.html"
when I using microsoft IE,It shows
"The page cannot be found ...."
but while using firefox
my test page was shown.
On Tue, 14 Dec 2004 22:16:17 -0400, Ivan Barrera A. <Br...@ivn.cl> wrote:
> Dont know if another person replied this but, i remember having trouble
> when my error pages where less than 1kb in size.
>
> Gare wrote:
> > No, 404 error are managed ok by apache, vhosts use the config of the main
> > (common) configuration. Malfunction appears in 403, 500 and others document
> > errors. And more, the problem too appears if document errors are
> > configurated inside vhosts section
> >
> > regards
> >
> > ----- Original Message -----
> > From: "Ralf Glauberman" <rg...@michaeli-gymnasium.de>
> > To: <us...@httpd.apache.org>
> > Sent: Monday, December 13, 2004 10:49 PM
> > Subject: Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
> >
> >
> >
> >>hi,
> >>just one idea, but is it for sure that apache will be able to know which
> >>vhost is active in an error-condition? i think it could be possible that
> >>apache wants absolute pathes here because it isn't sure if it will always
> >
> > be
> >
> >>able to know the right vhost. correct me, if i'm wrong.
> >>ralf
> >>
> >>----- Original Message -----
> >>From: Gare
> >>To: users@httpd.apache.org
> >>Sent: Monday, December 13, 2004 5:49 PM
> >>Subject: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
> >>
> >>
> >>My problem is that ErrorDocument doesn't redirect to the page I've
> >
> > configure
> >
> >>in httpd.conf if I don't use a absolute URL.
> >>My Apache server manage several virtual hosts, I have error page 404
> >>redirect to /error/404.htm. That's in the main section of httpd.conf I
> >>wrote:
> >>ErrorDocument 400 /error/400.htm
> >>ErrorDocument 401 /error/401.htm
> >>ErrorDocument 402 /error/402.htm
> >>ErrorDocument 403 /error/403.htm
> >>ErrorDocument 404 /error/404.htm
> >>ErrorDocument 500 /error/500.htm
> >>
> >>Error 404 (page not faound) works right, but 403 or 500 go to defaul
> >
> > pages.
> >
> >>But if I put
> >>ErrorDocument 403 http://mydomain.com/error/403.htm
> >>
> >>then page 403 is redirected to the correct page.
> >>
> >>I've tried to write the ErrorDocument configuration sentences inside
> >
> > virtual
> >
> >>host directive, but the problem is the same.
> >>(Apache 1.3.3)
> >>
> >>Any idea of where is my mistake?
> >>
> >>
> >>---------------------------------------------------------------------
> >>The official User-To-User support forum of the Apache HTTP Server Project.
> >>See <URL:http://httpd.apache.org/userslist.html> for more info.
> >>To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> >> " from the digest: users-digest-unsubscribe@httpd.apache.org
> >>For additional commands, e-mail: users-help@httpd.apache.org
> >>
> >>
> >
> >
> >
> >
> > ---------------------------------------------------------------------
> > The official User-To-User support forum of the Apache HTTP Server Project.
> > See <URL:http://httpd.apache.org/userslist.html> for more info.
> > To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> > " from the digest: users-digest-unsubscribe@httpd.apache.org
> > For additional commands, e-mail: users-help@httpd.apache.org
> >
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
Posted by "Ivan Barrera A." <Br...@Ivn.cl>.
Dont know if another person replied this but, i remember having trouble
when my error pages where less than 1kb in size.
Gare wrote:
> No, 404 error are managed ok by apache, vhosts use the config of the main
> (common) configuration. Malfunction appears in 403, 500 and others document
> errors. And more, the problem too appears if document errors are
> configurated inside vhosts section
>
> regards
>
> ----- Original Message -----
> From: "Ralf Glauberman" <rg...@michaeli-gymnasium.de>
> To: <us...@httpd.apache.org>
> Sent: Monday, December 13, 2004 10:49 PM
> Subject: Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
>
>
>
>>hi,
>>just one idea, but is it for sure that apache will be able to know which
>>vhost is active in an error-condition? i think it could be possible that
>>apache wants absolute pathes here because it isn't sure if it will always
>
> be
>
>>able to know the right vhost. correct me, if i'm wrong.
>>ralf
>>
>>----- Original Message -----
>>From: Gare
>>To: users@httpd.apache.org
>>Sent: Monday, December 13, 2004 5:49 PM
>>Subject: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
>>
>>
>>My problem is that ErrorDocument doesn't redirect to the page I've
>
> configure
>
>>in httpd.conf if I don't use a absolute URL.
>>My Apache server manage several virtual hosts, I have error page 404
>>redirect to /error/404.htm. That's in the main section of httpd.conf I
>>wrote:
>>ErrorDocument 400 /error/400.htm
>>ErrorDocument 401 /error/401.htm
>>ErrorDocument 402 /error/402.htm
>>ErrorDocument 403 /error/403.htm
>>ErrorDocument 404 /error/404.htm
>>ErrorDocument 500 /error/500.htm
>>
>>Error 404 (page not faound) works right, but 403 or 500 go to defaul
>
> pages.
>
>>But if I put
>>ErrorDocument 403 http://mydomain.com/error/403.htm
>>
>>then page 403 is redirected to the correct page.
>>
>>I've tried to write the ErrorDocument configuration sentences inside
>
> virtual
>
>>host directive, but the problem is the same.
>>(Apache 1.3.3)
>>
>>Any idea of where is my mistake?
>>
>>
>>---------------------------------------------------------------------
>>The official User-To-User support forum of the Apache HTTP Server Project.
>>See <URL:http://httpd.apache.org/userslist.html> for more info.
>>To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
>> " from the digest: users-digest-unsubscribe@httpd.apache.org
>>For additional commands, e-mail: users-help@httpd.apache.org
>>
>>
>
>
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
Posted by Gare <ga...@wanadoo.es>.
No, 404 error are managed ok by apache, vhosts use the config of the main
(common) configuration. Malfunction appears in 403, 500 and others document
errors. And more, the problem too appears if document errors are
configurated inside vhosts section
regards
----- Original Message -----
From: "Ralf Glauberman" <rg...@michaeli-gymnasium.de>
To: <us...@httpd.apache.org>
Sent: Monday, December 13, 2004 10:49 PM
Subject: Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
> hi,
> just one idea, but is it for sure that apache will be able to know which
> vhost is active in an error-condition? i think it could be possible that
> apache wants absolute pathes here because it isn't sure if it will always
be
> able to know the right vhost. correct me, if i'm wrong.
> ralf
>
> ----- Original Message -----
> From: Gare
> To: users@httpd.apache.org
> Sent: Monday, December 13, 2004 5:49 PM
> Subject: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
>
>
> My problem is that ErrorDocument doesn't redirect to the page I've
configure
> in httpd.conf if I don't use a absolute URL.
> My Apache server manage several virtual hosts, I have error page 404
> redirect to /error/404.htm. That's in the main section of httpd.conf I
> wrote:
> ErrorDocument 400 /error/400.htm
> ErrorDocument 401 /error/401.htm
> ErrorDocument 402 /error/402.htm
> ErrorDocument 403 /error/403.htm
> ErrorDocument 404 /error/404.htm
> ErrorDocument 500 /error/500.htm
>
> Error 404 (page not faound) works right, but 403 or 500 go to defaul
pages.
> But if I put
> ErrorDocument 403 http://mydomain.com/error/403.htm
>
> then page 403 is redirected to the correct page.
>
> I've tried to write the ErrorDocument configuration sentences inside
virtual
> host directive, but the problem is the same.
> (Apache 1.3.3)
>
> Any idea of where is my mistake?
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
Posted by Joshua Slive <js...@gmail.com>.
On Mon, 13 Dec 2004 22:49:18 +0100, Ralf Glauberman
<rg...@michaeli-gymnasium.de> wrote:
> hi,
> just one idea, but is it for sure that apache will be able to know which
> vhost is active in an error-condition? i think it could be possible that
> apache wants absolute pathes here because it isn't sure if it will always be
> able to know the right vhost. correct me, if i'm wrong.
You're wrong ;-)
As I said, ErrorDocument *always* takes a URL-path and not a file-system path.
Yes, there may be conditions where Apache doesn't know the vhost. In
this case, it will use the default vhost for that IP address.
Joshua.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
Posted by Ralf Glauberman <rg...@michaeli-gymnasium.de>.
hi,
just one idea, but is it for sure that apache will be able to know which
vhost is active in an error-condition? i think it could be possible that
apache wants absolute pathes here because it isn't sure if it will always be
able to know the right vhost. correct me, if i'm wrong.
ralf
----- Original Message -----
From: Gare
To: users@httpd.apache.org
Sent: Monday, December 13, 2004 5:49 PM
Subject: [users@httpd] ErrorDocument 403 and so doe'nt redirect properly
My problem is that ErrorDocument doesn't redirect to the page I've configure
in httpd.conf if I don't use a absolute URL.
My Apache server manage several virtual hosts, I have error page 404
redirect to /error/404.htm. That's in the main section of httpd.conf I
wrote:
ErrorDocument 400 /error/400.htm
ErrorDocument 401 /error/401.htm
ErrorDocument 402 /error/402.htm
ErrorDocument 403 /error/403.htm
ErrorDocument 404 /error/404.htm
ErrorDocument 500 /error/500.htm
Error 404 (page not faound) works right, but 403 or 500 go to defaul pages.
But if I put
ErrorDocument 403 http://mydomain.com/error/403.htm
then page 403 is redirected to the correct page.
I've tried to write the ErrorDocument configuration sentences inside virtual
host directive, but the problem is the same.
(Apache 1.3.3)
Any idea of where is my mistake?
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org