我怎么能回应。将一个页面重定向()到具有隐藏扩展的其他页面 [英] how can i responce. redirect() one page to other page with hidden extencetion
本文介绍了我怎么能回应。将一个页面重定向()到具有隐藏扩展的其他页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我怎么能响应.redirect()一页到其他页面隐藏的扩展名
protected void Page_Load(object sender,EventArgs e)
{
Response.Redirect(〜/ Index_Menu / IndexHome.aspx);
}
我不会,显示网址为 〜/ Index_Menu / Home。
// Home = IndexHome.aspx
解决方案
HI,
你的意思是你想重写URL。你可以使用urlrewrinting.net来做到这一点。它是一个重写URl的免费工具。
如果你在框架4.0中使用MVC那么它有一些内置功能来进行URL重写。
http://weblogs.asp.net/scottgu/archive/2009/10/ 13 / url-routing-with-asp-net-4-web-forms-vs-2010-and-net-4-0-series.aspx [ ^ ]
或者您可以使用IIS 7或更高版本的URL重写模块
http://www.iis.net/learn/extensions/url-rewrite -module [ ^ ]
how can i response.redirect() one page to other page with hidden extension
protected void Page_Load(object sender, EventArgs e)
{
Response.Redirect("~/Index_Menu/IndexHome.aspx");
}
and i wont, show url as "~/Index_Menu/Home".
// Home=IndexHome.aspx
解决方案
HI,
do you mean you want to rewrite URL. you can do it by using urlrewrinting.net. it is a free tools for rewrite URl.
if you are using MVC with framework 4.0 then it have some inbuilt features to do URL rewrite.
http://weblogs.asp.net/scottgu/archive/2009/10/13/url-routing-with-asp-net-4-web-forms-vs-2010-and-net-4-0-series.aspx[^]
OR you can use URL rewrite module from IIS 7 or greater
http://www.iis.net/learn/extensions/url-rewrite-module[^]
这篇关于我怎么能回应。将一个页面重定向()到具有隐藏扩展的其他页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文