Re: Sending 304 reponses
Re: Sending 304 reponses
- Subject: Re: Sending 304 reponses
- From: Johann Werner <email@hidden>
- Date: Thu, 06 Jun 2013 09:26:33 +0200
Hi Tarun,
the entry point for requests is ERXApplication.createRequest(…) that you could override in you application class. There you can access header values and decide to end the request without further computation by returning null. Another place would be ERXApplication.dispatchRequest(…) where you have already a WORequest object to work with and where you could return an arbitrary WOResponse object to be sent back to the client. The next location would be the WORequestHandler.handleRequest(…) but to override that you would need to create a subclass of the specific request handler and register that one so WO uses it instead of the original handler.
All depends on how you are able to determine if the requested resource has not been modified / how much of the RR-loop has to be covered.
jw
Am 31.03.2013 um 18:16 schrieb Tarun Reddy <email@hidden>:
> So I've managed to add Last-modified headers to my applications responses, but what is the best way to check for If-Modified-Since and do the appropriate thing?
>
> I'm using postAppendToResponse for Last-modifed. Is there something similar that I can use to intercept the request early before the page gets built?
>
> Thank you,
> Tarun
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden