url如何重定向 请大家帮忙

wpfonline 2007-08-07 04:44:24
我想把地址栏上的 "http://marry.inhe.net/Center/ShowNews/ShowNews.aspx?id=5033"
在地址栏上显示为"http://marry.inhe.net/Center/ShowNews/ShowNews.aspx/5033"
不知道如何实现 请大家帮助
...全文
199 12 打赏 收藏 转发到动态 举报
写回复
用AI写文章
12 条回复
切换为时间正序
请发表友善的回复…
发表回复
wpfonline 2007-08-08
  • 打赏
  • 举报
回复
谢楼上了
  • 打赏
  • 举报
回复
wpfonline(无知) ( ) 信誉:100 2007-08-07 17:30:24 得分: 0


flysky862() ( ) 信誉:100
的那种怎么实现在 可以说一下吗??


——————————————————————————————————————————

我以前回果一个帖子:http://community.csdn.net/Expert/topic/5645/5645189.xml?temp=.6197473


我的其它部分回复可以看:http://www.google.com/advanced_search?q=sp1234+site:community.csdn.net&hl=zh-CN&lr=&newwindow=1&rls=com.microsoft:en-US&as_qdr=all

同样方法,可以看看别人的回复。
iswitch 2007-08-07
  • 打赏
  • 举报
回复
请问 为什么要这么改?
把 "http://marry.inhe.net/Center/ShowNews/ShowNews.aspx?id=5033" 改成
http://marry.inhe.net/Center/ShowNews/ShowNews.aspx/5033"
有什么好处么?
Eri 2007-08-07
  • 打赏
  • 举报
回复
我想把地址栏上的 "http://marry.inhe.net/Center/ShowNews/ShowNews.aspx?id=5033"
在地址栏上显示为"http://marry.inhe.net/Center/ShowNews/ShowNews.aspx/5033"


http://marry.inhe.net/Center/ShowNews/ShowNews/5033

这样好看一点。
commonmj 2007-08-07
  • 打赏
  • 举报
回复
搜索url重写,很多
微软有个可以下载的dll提供了这个功能,2.0可以直接在web.config 里面配置
hsabout 2007-08-07
  • 打赏
  • 举报
回复
flysky862()的應該也可以這樣完成啊
if(!IsPostBack)
{
if(Request.QueryString["id"]!=null)
{
Response.Redirect("http://marry.inhe.net/Center/ShowNews/"+Request.QueryString["id"].Trim()+".aspx");
}
}
wpfonline 2007-08-07
  • 打赏
  • 举报
回复
flysky862() ( ) 信誉:100
的那种怎么实现在 可以说一下吗??
地下室小红叔 2007-08-07
  • 打赏
  • 举报
回复
通过自定义模块 捕捉request事件 可以实现
大海008 2007-08-07
  • 打赏
  • 举报
回复
晕,怎么会这样呢,我也一直想实现这样的效果,但我只实现了如下效果:
我想把地址栏上的 "http://marry.inhe.net/Center/ShowNews/ShowNews.aspx?id=5033"
在地址栏上显示为"http://marry.inhe.net/Center/ShowNews/5033.aspx"
hsabout 2007-08-07
  • 打赏
  • 举报
回复
if(!IsPostBack)
{
if(Request.QueryString["id"]!=null&&Request.QueryString["id"]="5033")
{
Response.Redirect("http://marry.inhe.net/Center/ShowNews/ShowNews.aspx/5033");
}
}
================================================
這樣
if(!IsPostBack)
{
if(Request.QueryString["id"]!=null)
{
Response.Redirect("http://marry.inhe.net/Center/ShowNews/ShowNews.aspx/"+Request.QueryString["id"].Trim());
}
}
hsabout 2007-08-07
  • 打赏
  • 举报
回复
if(!IsPostBack)
{
if(Request.QueryString["id"]!=null&&Request.QueryString["id"]="5033")
{
Response.Redirect("http://marry.inhe.net/Center/ShowNews/ShowNews.aspx/5033");
}
}
shuo_shu 2007-08-07
  • 打赏
  • 举报
回复
脚本实现就可以了。

也可以使用transfer简单的实现

62,054

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术交流专区
javascript云原生 企业社区
社区管理员
  • ASP.NET
  • .Net开发者社区
  • R小R
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

.NET 社区是一个围绕开源 .NET 的开放、热情、创新、包容的技术社区。社区致力于为广大 .NET 爱好者提供一个良好的知识共享、协同互助的 .NET 技术交流环境。我们尊重不同意见,支持健康理性的辩论和互动,反对歧视和攻击。

希望和大家一起共同营造一个活跃、友好的社区氛围。

试试用AI创作助手写篇文章吧