如何在DNN中重写查询字符串URL

时间:2013-11-19 06:26:36

标签: asp.net c#-4.0 url-rewriting dotnetnuke

我正在使用DNN(DotNetNuke)6,我的网址如下,

http://localhost/Training/rpscategory.aspx?P=Oracle&Cat=Middleware

我想重写上面的网址,

http://localhost/Training/Oracle/Middleware

http://localhost/Training/rpscategory.aspx?P=Oracle&Cat=Middleware&Course=Monitor-and-Performance

我想重写上面的网址,

http://localhost/Training/Oracle/Middleware/Monitor-and-Performance

如何实现这个

先谢谢

2 个答案:

答案 0 :(得分:0)

http://www.asp.net/mvc/tutorials/controllers-and-routing/creating-custom-routes-cs

UrlRouting更有用且易于理解请参阅此链接。 。它肯定会帮助你

第二个选项

UrlRewrite选项在IIS中也很容易使用.IIS将此作为内置功能提供。 你必须将urlrewrite添加到iis,它可以从网上下载,只需在IIS中添加你的网址(Url Rewrite)它会自动更改你的WebConfig和Url转换为用户友好的URl。

:-)

答案 1 :(得分:0)

我已使用OpenUrlRewriter

在DNN中实现了重写查询字符串URL

Here is in detail..