重温url重写

url重写,其DLL下载地址
http://space.itpub.net/batch.download.php?aid=23476

具体的使用说明请去看http://msdn.microsoft.com/zh-cn/library/ms972974.aspx#XSLTsection123121120120


使用方法
1.  引用DLL
2. 在节点加入    


   
 
   
     
     

     
     

   

 
 

3.找到authentication 的mode改为
<httpModules>
            
<add type="URLRewriter.ModuleRewriter, URLRewriter" name="ModuleRewriter"/>
 
httpModules>

4.这样已经可以了,但在页面回发后又会出现原来的地址。你需要在把所有页面的头部加上:

<%@ Register TagPrefix="skm" Namespace="ActionlessForm" Assembly="ActionlessForm" %> 把From换成


OK,已经可以了。

5.你可以添加多条规则,里面加入模块配置

  
    
     //重写为html需要IIS中配置映射。
  

 在处理回发的页面加入以下代码

try{documnt.forms[0].action=""}catch(ex){}

解决回发时显示真实地址的问题

 例子:

    

  


  

    

      

      

      

    

  


其它URL重写的方法
http://www.cnblogs.com/liulun/archive/2008/08/16/1265858.html

请使用浏览器的分享功能分享到微信等