如何在按钮单击时显示重写的URL [英] how to display the rewritten url on button click

查看:95
本文介绍了如何在按钮单击时显示重写的URL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我曾使用IIS 7重写URL,我的URL重写已成功完成。我希望在每次按钮点击时显示重写的URL,但仅显示原始URL。请让我知道如何只显示重写的URL ...

I had used the IIS 7 to rewrite URL, my URL rewriting has be accomplished successfully . I want that rewritten url to be displayed on every button click but the original url is only displayed. Please let me know how to display the rewritten URL only...

推荐答案

查看本文关于如何使用UI定义规则 - http://www.iis.net/learn/extensions/url- rewrite-module / creating-rewrite-rules-for-url-rewrite-module [ ^ ]

在定义行动部分中选择'重定向'而不是默认的'重写'...
See this article about how to define rules using UI - http://www.iis.net/learn/extensions/url-rewrite-module/creating-rewrite-rules-for-the-url-rewrite-module[^]
In the section 'DEFINING AN ACTION' choose 'Redirect' instead of the default 'Rewrite'...


Response.Redirect(URL)应该适合你。
Response.Redirect(URL) should work for you.


你能分享吗?您创建的ARR规则。我希望模式不匹配,这就是你没有被重定向到新URL的原因。


- Maheswaran.S
Can you share the ARR rule that you have created. I hope the pattern is not matching that is the reason you are not getting redirected to new URL.

- Maheswaran.S


这篇关于如何在按钮单击时显示重写的URL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆