Hey agentzh,<br><br>Very nice module. Good job and thanks!<br><br><br><div class="gmail_quote">On Tue, Nov 17, 2009 at 6:00 PM, agentzh <span dir="ltr"><<a href="mailto:agentzh@gmail.com">agentzh@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi, folks!<br>
<br>
After two days' work, I've now got the "headers_more" module passing<br>
the its own test suite. This is an enhanced version of the standard<br>
"headers" module because it provides more utilities like resetting or<br>
clearing output headers. Builtin headers, like "Content-Type",<br>
"Content-Length", and "Server", are also manipulatable ;)<br>
<br>
It also allows you to specify an optional HTTP status code criteria<br>
using the -s option and an optional content type criteria using the -t<br>
option.<br>
<br>
Here's some random use cases:<br>
<br>
more_set_headers 'Server: my-server';<br>
<br>
location /foo {<br>
more_set_headers 'X-MyHeader: blah' 'X-MyHeader2: foo';<br>
more_set_headers -t 'text/plain text/css' 'Content-Type: text/foo';<br>
more_set_headers -s '400 404 500 503' 'Foo: Bar';<br>
more_clear_headers 'Transfer-Encoding' 'Content-Type';<br>
}<br>
<br>
location /type {<br>
more_set_headers 'Content-Type: text/plain';<br>
}<br>
<br>
One important TODO is to allow variables within the new headers'<br>
values. That's where "headers_more" is "less" than the standard<br>
"headers" module :P<br>
<br>
The Git source repository is here:<br>
<br>
<a href="http://github.com/agentzh/headers-more-nginx-module" target="_blank">http://github.com/agentzh/headers-more-nginx-module</a><br>
<br>
And you're recommended to use the tarballs for the tagged releases:<br>
<br>
<a href="http://github.com/agentzh/headers-more-nginx-module/downloads" target="_blank">http://github.com/agentzh/headers-more-nginx-module/downloads</a><br>
<br>
Don't hesitate to report any issues that you find ;)<br>
<br>
Enjoy!<br>
<font color="#888888">-agentzh<br>
<br>
</font></blockquote></div><br clear="all"><br>-- <br>Joshua Zhu<br><a href="http://www.zhuzhaoyuan.com">http://www.zhuzhaoyuan.com</a><br>