如何从web.config中的url中检查params
我想将此URL的结果
www.test.com/shop/?wc-ajax=update_order_review
与任何其他URL分开:
www.test.com/shop/?param=update_order_review
www.test.com/shop//
www.test.com/shop
以及我所寻找的其他URL的结果,将其他URL重定向到另一个页面,例如:“ http://test.com/products”
注:此条件仅在/shop上工作/ 文件夹。
<rule name="rule01" patternSyntax="Wildcard" stopProcessing="true">
<match url="^(.*)test.com/shop/?wc-ajax=update_order_review" />
<action type="Redirect" url="https://www.test.co/products/" ppendQueryString="false" />
<serverVariables>
</serverVariables>
</rule>
I want to divide result of this url
www.test.com/shop/?wc-ajax=update_order_review
With any other url like:
www.test.com/shop/?param=update_order_review
www.test.com/shop//
www.test.com/shop
And what I looking, result of other Url redirect to another page, like: "http://test.com/products"
Note: This condition only works on /shop/ folder.
<rule name="rule01" patternSyntax="Wildcard" stopProcessing="true">
<match url="^(.*)test.com/shop/?wc-ajax=update_order_review" />
<action type="Redirect" url="https://www.test.co/products/" ppendQueryString="false" />
<serverVariables>
</serverVariables>
</rule>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论