» »

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?

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.

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...


Vredno ogleda ...

TemaSporočilaOglediZadnje sporočilo
TemaSporočilaOglediZadnje sporočilo
»

Apache - localhost JA, IP naslov NE

Oddelek: Omrežja in internet
182623 (2482) ManDriver
»

not found->po svoje

Oddelek: Izdelava spletišč
5895 (807) tx-z
»

Kako narediti redirect, če uporabnik vpiše napačno ime .html

Oddelek: Izdelava spletišč
161319 (1220) darh
»

Težave z WEB serverjem

Oddelek: Omrežja in internet
5927 (791) SLOWWWeb.net
»

w2k boot - blue screen

Oddelek: Operacijski sistemi
81565 (1469) matevzm

Več podobnih tem