Forum » Izdelava spletišč » Apache ErrorDocument 404 se ne prikaze v MSIE
Apache ErrorDocument 404 se ne prikaze v MSIE
poweroff ::
Hmm, problem je naslednji:
V apacheju (httpd.conf) imam takole definirano custom sporočilo o napaki:
ErrorDocument 404 /errors/error404.html
Tako imam sicer definirane tudi druge napake. OK, zdaj grem v MSIE (6.0, vsi popravki up-to-date) in ukucam en neobstoječ link. MSIE mi ne vrne error404.html, pač pa standardno The page cannot be found.
Isto poiskusim v Mozilli, pa lepo dela.
Zdaj preiskusim še dostop do prepovedane strani. Tu MSIE in Mozilla lepo prikažeta error403.html.
error404.tml pa ne vsebuje nič čudnega. Je praktično enak kot error403.html
Error404.html tudi čisto lepo preberem, če dostopam do njega preko direktnega URLja.
Ista finta je z HTTPS.
Očitno se ne razumeza MSIE in apache. A kdo ve v čem je finta?
V apacheju (httpd.conf) imam takole definirano custom sporočilo o napaki:
ErrorDocument 404 /errors/error404.html
Tako imam sicer definirane tudi druge napake. OK, zdaj grem v MSIE (6.0, vsi popravki up-to-date) in ukucam en neobstoječ link. MSIE mi ne vrne error404.html, pač pa standardno The page cannot be found.
Isto poiskusim v Mozilli, pa lepo dela.
Zdaj preiskusim še dostop do prepovedane strani. Tu MSIE in Mozilla lepo prikažeta error403.html.
error404.tml pa ne vsebuje nič čudnega. Je praktično enak kot error403.html
Error404.html tudi čisto lepo preberem, če dostopam do njega preko direktnega URLja.
Ista finta je z HTTPS.
Očitno se ne razumeza MSIE in apache. A kdo ve v čem je finta?
poweroff ::
OK, našel rešitev. Problem je seveda SPET!!!!!!!!!!!!!!!!!1 v #$%&#@ Microsoftu.
Torej:
< !--
-- Unfortunately, Microsoft has added a clever new
-- "feature" to Internet Explorer. If the text in
-- an error's message is "too small", specifically
-- less than 512 bytes, Internet Explorer returns
-- its own error message. Yes, you can turn that
-- off, but *surprise* it's pretty tricky to find
-- buried as a switch called "smart error
-- messages" That means, of course, that many of
-- Resin's error messages are censored by default.
-- And, of course, you'll be shocked to learn that
-- IIS always returns error messages that are long
-- enough to make Internet Explorer happy. The
-- workaround is pretty simple: pad the error
-- message with a big comment to push it over the
-- five hundred and twelve byte minimum. Of course,
-- that's exactly what you're reading right now.
//-- >
Samo tole je treba skopirati v error404.html, pa dela.
Torej:
< !--
-- Unfortunately, Microsoft has added a clever new
-- "feature" to Internet Explorer. If the text in
-- an error's message is "too small", specifically
-- less than 512 bytes, Internet Explorer returns
-- its own error message. Yes, you can turn that
-- off, but *surprise* it's pretty tricky to find
-- buried as a switch called "smart error
-- messages" That means, of course, that many of
-- Resin's error messages are censored by default.
-- And, of course, you'll be shocked to learn that
-- IIS always returns error messages that are long
-- enough to make Internet Explorer happy. The
-- workaround is pretty simple: pad the error
-- message with a big comment to push it over the
-- five hundred and twelve byte minimum. Of course,
-- that's exactly what you're reading right now.
//-- >
Samo tole je treba skopirati v error404.html, pa dela.
Ales ::
Pa še pod Internet Options -> Advanced (al nekaj takega, sem na linuxu pa ne morem pogledat) je fajn poiskat Smart Error Messages in izklopit... Sej niti ni tok skrito...
Tko vidiš še custom error strani od tistih, ki tega 512 šmorna nimajo not...
Tko vidiš še custom error strani od tistih, ki tega 512 šmorna nimajo not...
Vredno ogleda ...
Tema | Ogledi | Zadnje sporočilo | |
---|---|---|---|
Tema | Ogledi | Zadnje sporočilo | |
» | Apache - localhost JA, IP naslov NEOddelek: Omrežja in internet | 6623 (6482) | ManDriver |
» | not found->po svojeOddelek: Izdelava spletišč | 952 (864) | tx-z |
» | Kako narediti redirect, če uporabnik vpiše napačno ime .htmlOddelek: Izdelava spletišč | 1424 (1325) | darh |
» | Težave z WEB serverjemOddelek: Omrežja in internet | 994 (858) | SLOWWWeb.net |
» | w2k boot - blue screenOddelek: Operacijski sistemi | 1632 (1536) | matevzm |