Welcome! Log In Create A New Profile

Advanced

Re: Setting cache control and expires inside a module

Maxim Dounin
April 26, 2012 10:34AM
Hello!

On Thu, Apr 26, 2012 at 10:04:29AM -0300, Wandenberg Peixoto wrote:

> Hi Brian,
>
> I need to this inside my module, it already exists.
> Actually it responds to GET method and I need to add response to OPTIONS
> methods to support cross domain access,
> but want to send the response with cache headers, only for OPTIONS.
> This is the reason I need to do that by code.

I really wonder why you ever asked, I'm pretty sure you'll be able
to write correct code yourself. See ngx_http_set_expires() in
ngx_http_headers_module.c for an example.

Maxim Dounin

>
> Regards,
> Wandenberg
>
> On Thu, Apr 26, 2012 at 8:19 AM, Brian Akins <brian@akins.org> wrote:
>
> >
> > On Apr 25, 2012, at 12:15 AM, Wandenberg Peixoto wrote:
> > > I need to add response to OPTIONS method to a module to allow cross
> > domain access,
> > > but I want to set cache control and expires headers, only for this
> > method, to browsers does not ask this method frequently.
> >
> > I did this in a simple Lua script. Could do the same with perl.
> >
> > _______________________________________________
> > nginx-devel mailing list
> > nginx-devel@nginx.org
> > http://mailman.nginx.org/mailman/listinfo/nginx-devel
> >

> _______________________________________________
> nginx-devel mailing list
> nginx-devel@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx-devel

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

Setting cache control and expires inside a module

wandenberg 1423 April 25, 2012 12:16AM

Re: Setting cache control and expires inside a module

Brian Akins 504 April 26, 2012 07:20AM

Re: Setting cache control and expires inside a module

wandenberg 560 April 26, 2012 09:06AM

Re: Setting cache control and expires inside a module

Maxim Dounin 673 April 26, 2012 10:34AM

Re: Setting cache control and expires inside a module

wandenberg 793 April 26, 2012 08:56PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 136
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready