<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<STYLE type=text/css> <!--@import url(C:\Program Files\Netease\网易闪电邮\\data\scrollbar.css); --></STYLE>

<META http-equiv=Content-Type content="text/html; charset=utf-8">
<STYLE>BLOCKQUOTE{margin-Top: 0px; margin-Bottom: 0px; margin-Left: 2em};                                                    body{FONT-SIZE:12pt; FONT-FAMILY:宋体,serif;};                                                    </STYLE>

<META content="MSHTML 6.00.2900.5945" name=GENERATOR><BASE target=_blank></HEAD>
<BODY 
style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; MARGIN: 12px; BORDER-RIGHT-WIDTH: 0px" 
marginheight="0" marginwidth="0"><STATIONERY>
<DIV>
<DIV><FONT face=宋体 color=#000000 size=3>ok.Thanks for your reply.</FONT></DIV>
<DIV><FONT face=宋体 color=#000000 size=3></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Verdana color=#c0c0c0 
size=2>2010-05-31</FONT></DIV><FONT face=Verdana size=2>
<HR style="WIDTH: 122px; HEIGHT: 2px" align=left SIZE=2>

<DIV><FONT face=Verdana color=#c0c0c0 size=2><SPAN 
id=_FlashSignName>jyf832004</SPAN></FONT></DIV></FONT>
<DIV>
<HR>
</DIV>
<DIV>发件人: Yuriy Taraday &lt;yorik.sar@gmail.com&gt;</DIV>
<DIV>发送时间: 2010-05-31 12:39</DIV>
<DIV>主 题: Re: Re: Re: uri and sub-uri</DIV>
<DIV>收件人: nginx-devel@nginx.org</DIV>
<DIV><BR><BR></DIV>Well, this problem can not be solved in common case. You can 
use expressions like "/anything/(.*).php$" and no robot can extract concrete uri 
tree from them.
<DIV>If you have some your own locations' structure, you should write your own 
module that will walk throw them. You can use autoindex module as base.<BR><BR>
<DIV class=gmail_quote>2010/5/31 jyf832004 <SPAN dir=ltr>&lt;<A 
href="mailto:jyf832004@163.com" 
target=_blank>jyf832004@163.com</A>&gt;</SPAN><BR>
<BLOCKQUOTE class=gmail_quote 
style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
  <DIV 
  style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; MARGIN: 12px; BORDER-RIGHT-WIDTH: 0px" 
  marginheight="0" marginwidth="0">
  <DIV><FONT face=宋体 color=#000000 size=3></FONT>&nbsp;</DIV>
  <DIV><FONT face=宋体 color=#000000 size=3></FONT>&nbsp;</DIV>
  <DIV align=left><FONT face=Verdana color=#c0c0c0 
  size=2>2010-05-31</FONT></DIV><FONT face=Verdana size=2>
  <DIV>
  <HR style="MIN-HEIGHT: 2px; WIDTH: 122px" align=left SIZE=2>
  </DIV>
  <DIV><FONT face=Verdana color=#c0c0c0 
  size=2><SPAN>jyf832004</SPAN></FONT></DIV></FONT>
  <DIV>
  <HR>
  </DIV>
  <DIV>发件人: Yuriy Taraday &lt;<A href="mailto:yorik.sar@gmail.com" 
  target=_blank>yorik.sar@gmail.com</A>&gt;</DIV>
  <DIV>发送时间: 2010-05-31 11:24</DIV>
  <DIV>主 题: Re: Re: uri and sub-uri</DIV>
  <DIV>
  <DIV>收件人: <A href="mailto:nginx-devel@nginx.org" 
  target=_blank>nginx-devel@nginx.org</A></DIV>
  <DIV><BR><BR></DIV></DIV>
  <DIV>
  <DIV>How do you expect nginx to find out which uri's valid for your 
  module?</DIV></DIV>
  <DIV>It may be done in nginx.conf with regex,something like this:</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>location 
  "~^(/system/syslog)(/?$|/[0-9]{2}-[0-9]{2}-[0-9]{4}$)"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  system_syslog on;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  }<BR></DIV>
  <DIV>In my design,every uri&nbsp;act as a&nbsp;node and it should have a 
  parent node expect for the root node,and have a child node expect for the leaf 
  node.And when i</DIV>
  <DIV>go to one node,and&nbsp;its child nodes&nbsp;can be listed.So i guess 
  nginx can remeber a uri and its parent uri and child uris in some structure,i 
  don't know if&nbsp;it exists.&nbsp;</DIV>
  <DIV>
  <DIV></DIV>
  <DIV>
  <DIV><BR>
  <DIV class=gmail_quote>On Mon, May 31, 2010 at 7:02 AM, jyf832004 <SPAN 
  dir=ltr>&lt;<A href="mailto:jyf832004@163.com" 
  target=_blank>jyf832004@163.com</A>&gt;</SPAN> wrote:<BR>
  <BLOCKQUOTE class=gmail_quote 
  style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
    <DIV 
    style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; MARGIN: 12px; BORDER-RIGHT-WIDTH: 0px" 
    marginheight="0" marginwidth="0">
    <DIV>
    <DIV><FONT face=宋体 color=#000000 size=3>Thanks Weibin:</FONT></DIV>
    <DIV><FONT face=宋体 color=#000000 size=3>This module provides automatic 
    directory listings,in my opinion,it only list static files under some 
    directory.</FONT></DIV>
    <DIV><FONT face=宋体 color=#000000 size=3>But my sub-uris are written in the 
    nginx.conf file,which are identified by location directive </FONT></DIV>
    <DIV><FONT face=宋体 color=#000000 size=3>and are not mapped to some physical 
    directory </FONT></DIV>
    <DIV><FONT face=宋体 color=#000000 size=3>but handled by&nbsp;modules written 
    by me.</FONT></DIV>
    <DIV><FONT face=宋体 color=#000000 size=3>any suggestion? </FONT></DIV>
    <DIV><FONT face=宋体 color=#000000 size=3>Thank you.</FONT></DIV>
    <DIV><FONT face=宋体 color=#000000 size=3></FONT>&nbsp;</DIV>
    <DIV align=left><FONT face=Verdana color=#c0c0c0 
    size=2>2010-05-31</FONT></DIV><FONT face=Verdana size=2>
    <HR style="MIN-HEIGHT: 2px; WIDTH: 122px" align=left SIZE=2>

    <DIV><FONT face=Verdana color=#c0c0c0 
    size=2><SPAN>jyf832004</SPAN></FONT></DIV></FONT><FONT color=#888888>
    <DIV>
    <HR>
    </DIV>
    <DIV>发件人: Weibin Yao &lt;<A href="mailto:nbubingo@gmail.com" 
    target=_blank>nbubingo@gmail.com</A>&gt;</DIV>
    <DIV>发送时间: 2010-05-31 10:28</DIV>
    <DIV>主 题: Re: uri and sub-uri</DIV>
    <DIV>收件人: <A href="mailto:nginx-devel@nginx.org" 
    target=_blank>nginx-devel@nginx.org</A></DIV></FONT>
    <DIV>
    <DIV></DIV>
    <DIV>
    <DIV><BR><BR></DIV>
    <DIV>jyf832004&nbsp;at&nbsp;2010-5-31&nbsp;10:06&nbsp;wrote:&nbsp;</DIV>
    <DIV>&gt;&nbsp;Hi,all:&nbsp;</DIV>
    <DIV>&gt;&nbsp;Can&nbsp;nginx&nbsp;support&nbsp;uri&nbsp;and&nbsp;sub-uri,for&nbsp;example,when&nbsp;i&nbsp;have&nbsp;a&nbsp;&nbsp;</DIV>
    <DIV>&gt;&nbsp;uri:<A href="http://www.example.com/system" 
    target=_blank>http://www.example.com/system</A>,&nbsp;and&nbsp;some&nbsp;sub-uris&nbsp;under&nbsp;&nbsp;</DIV>
    <DIV>&gt;&nbsp;it:<A 
    href="http://www.example.com/system/syslog,http://www.example.com/system/firmware,http://www.example.com/system/sysuser" 
    target=_blank>http://www.example.com/system/syslog,http://www.example.com/system/firmware,http://www.example.com/system/sysuser</A>.&nbsp;</DIV>
    <DIV>&gt;&nbsp;When&nbsp;i&nbsp;browse&nbsp;<A 
    href="http://www.example.com/system" 
    target=_blank>http://www.example.com/system</A>&nbsp;can&nbsp;nginx&nbsp;list&nbsp;the&nbsp;&nbsp;</DIV>
    <DIV>&gt;&nbsp;sub-uris&nbsp;above?&nbsp;</DIV>
    <DIV>&gt;&nbsp;Thank&nbsp;you&nbsp;very&nbsp;much!&nbsp;</DIV>
    <DIV>&nbsp;</DIV>
    <DIV><A href="http://wiki.nginx.org/NginxHttpAutoindexModule" 
    target=_blank>http://wiki.nginx.org/NginxHttpAutoindexModule</A>&nbsp;</DIV>
    <DIV>&nbsp;</DIV>
    <DIV>&gt;&nbsp;&nbsp;&nbsp;</DIV>
    <DIV>&gt;&nbsp;2010-05-31&nbsp;</DIV>
    <DIV>&gt;&nbsp;------------------------------------------------------------------------&nbsp;</DIV>
    <DIV>&gt;&nbsp;jyf832004&nbsp;</DIV>
    <DIV>&gt;&nbsp;------------------------------------------------------------------------&nbsp;</DIV>
    <DIV>&gt;&nbsp;</DIV>
    <DIV>&gt;&nbsp;_______________________________________________&nbsp;</DIV>
    <DIV>&gt;&nbsp;nginx-devel&nbsp;mailing&nbsp;list&nbsp;</DIV>
    <DIV>&gt;&nbsp;<A href="mailto:nginx-devel@nginx.org" 
    target=_blank>nginx-devel@nginx.org</A>&nbsp;</DIV>
    <DIV>&gt;&nbsp;<A href="http://nginx.org/mailman/listinfo/nginx-devel" 
    target=_blank>http://nginx.org/mailman/listinfo/nginx-devel</A>&nbsp;</DIV>
    <DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
    <DIV>&nbsp;</DIV>
    <DIV>&nbsp;</DIV>
    <DIV>--&nbsp;&nbsp;</DIV>
    <DIV>Weibin&nbsp;Yao&nbsp;</DIV>
    <DIV>&nbsp;</DIV>
    <DIV>&nbsp;</DIV>
    <DIV>_______________________________________________&nbsp;</DIV>
    <DIV>nginx-devel&nbsp;mailing&nbsp;list&nbsp;</DIV>
    <DIV><A href="mailto:nginx-devel@nginx.org" 
    target=_blank>nginx-devel@nginx.org</A>&nbsp;</DIV>
    <DIV><A href="http://nginx.org/mailman/listinfo/nginx-devel" 
    target=_blank>http://nginx.org/mailman/listinfo/nginx-devel</A>&nbsp;</DIV>
    <DIV></DIV></DIV></DIV></DIV></DIV><BR>_______________________________________________<BR>nginx-devel 
    mailing list<BR><A href="mailto:nginx-devel@nginx.org" 
    target=_blank>nginx-devel@nginx.org</A><BR><A 
    href="http://nginx.org/mailman/listinfo/nginx-devel" 
    target=_blank>http://nginx.org/mailman/listinfo/nginx-devel</A><BR><BR></BLOCKQUOTE></DIV><BR></DIV></DIV></DIV></DIV><BR>_______________________________________________<BR>nginx-devel 
  mailing list<BR><A href="mailto:nginx-devel@nginx.org" 
  target=_blank>nginx-devel@nginx.org</A><BR><A 
  href="http://nginx.org/mailman/listinfo/nginx-devel" 
  target=_blank>http://nginx.org/mailman/listinfo/nginx-devel</A><BR><BR></BLOCKQUOTE></DIV><BR></DIV></DIV></STATIONERY></BODY></HTML>