[opencms-dev] 404 not returning 404

Yusuf Kör mailinglist1 at koer.de
Tue Nov 15 13:05:16 CET 2005


Hi Alex,

I did the update from 6.0.0 to 6.0.2 but the error code problem still 
appears. I still get status code 200 back

thats the configuration part from web.xml
<error-page>
      <error-code>404</error-code>
      <!-- <location>/opencms/handle404</location> -->
      <location>/opencms/error404.html</location>
</error-page>
<error-page>
      <error-code>500</error-code>
      <!-- <location>/opencms/system/handler/handle500.html</location> -->
      <location>/opencms/error500.html</location>
 </error-page>

Should I set the return code explicitly 
<se?lp=ende&p=/Mn4k.&search=explicitly> in the error404.jsp or somewhere 
else?

kind regards,
Yusuf Kör


Alexander Kandzior wrote:

>Joe, 
>
>This appears to be a bug in the 6.0.0 release version. I will fix this in
>the CVS HEAD asasp.
>
>Best Regards,
>Alex.
>
>Alexander Kandzior
>Alkacon Software - The OpenCms Experts
>http://www.alkacon.com
>
> 
>
>  
>
>>-----Original Message-----
>>From: opencms-dev-bounces at opencms.org 
>>[mailto:opencms-dev-bounces at opencms.org] On Behalf Of Joe Desbonnet
>>Sent: Thursday, July 14, 2005 11:16 AM
>>To: The OpenCms mailing list
>>Subject: Re: [opencms-dev] 404 not returning 404
>>
>>Hi Andras,
>>
>>It is very important that the 404 page returns HTTP status 
>>code 404 and not 200. To humans it doesn't matter much, but 
>>to various types of robot that scan the site each day it 
>>makes a *big* difference.
>>
>>Example why it's a problem: Try googling for "opencms 404" 
>>(as I did when researching this problem). Half of the pages 
>>indexed there are OpenCms error messages and not site content.
>>
>>Joe.
>>
>>
>>
>>One example why it's a bad ide
>>
>>On 7/14/05, Andras Balogh <abalogh at gmail.com> wrote:
>>    
>>
>>>Hello Joe,
>>>
>>>    OpenCMS registers itself as 404 handler, this is 
>>>      
>>>
>>important for the 
>>    
>>
>>>feature "export on demand".
>>>Why do you want to return 404? Usually you could make a page with a 
>>>text
>>>like:
>>>"Page not found blabla ..."
>>>
>>>Best regards,
>>>Andras.
>>>
>>>Joe Desbonnet wrote:
>>>
>>>      
>>>
>>>>How do I get the 404 error handler to return a HTTP status code of 
>>>>404? Right now it seems to return 200.
>>>>
>>>>I tried
>>>>response.setStatus(404)
>>>>in /system/handler/handle404.html JSP script, but that 
>>>>        
>>>>
>>does not appear to work.
>>    
>>
>>>>I know this has been discussed before, but I cannot find the 
>>>>resolution of the problem. Ironically, Googling for "Opencms 404"
>>>>yields mostly 404 error pages on OpenCms sites which 
>>>>        
>>>>
>>Google mistakes 
>>    
>>
>>>>for content due to the 200 response code.
>>>>
>>>>Joe.
>>>>
>>>>
>>>>_______________________________________________
>>>>This mail is send to you from the opencms-dev mailing list 
>>>>        
>>>>
>>To change 
>>    
>>
>>>>your list options, or to unsubscribe from the list, please visit 
>>>>http://mail.opencms.org/mailman/listinfo/opencms-dev
>>>>
>>>>
>>>>
>>>>        
>>>>
>>>
>>>_______________________________________________
>>>This mail is send to you from the opencms-dev mailing list 
>>>      
>>>
>>To change 
>>    
>>
>>>your list options, or to unsubscribe from the list, please visit 
>>>http://mail.opencms.org/mailman/listinfo/opencms-dev
>>>
>>>      
>>>
>>_______________________________________________
>>This mail is send to you from the opencms-dev mailing list To 
>>change your list options, or to unsubscribe from the list, 
>>please visit http://mail.opencms.org/mailman/listinfo/opencms-dev
>>
>>
>>    
>>
>
>
>
>_______________________________________________
>This mail is send to you from the opencms-dev mailing list
>To change your list options, or to unsubscribe from the list, please visit
>http://mail.opencms.org/mailman/listinfo/opencms-dev
>
>  
>




More information about the opencms-dev mailing list