Windows服务器上的asp.net项目中的子域名网址 [英] subdomain url in asp.net project on windows server

查看:70
本文介绍了Windows服务器上的asp.net项目中的子域名网址的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Windows服务器上托管了asp.net网站,该网站不支持创建子域名的通配符(*。)。

我必须重定向网址:http:// subdomain .domainName.org到http://domainName.org



如何以编程方式实现此目的?

解决方案

< blockquote>在global.asax文件中使用路由将路由从请求的

 http://subdomain.domainName.org 

更改为

 http:/ /domainName.org 


I Hosted the asp.net website on windows server which does not support the wild card entry(*.) for the subdomain creation.
I have to redirect the url : http://subdomain.domainName.org to http://domainName.org

how can I achieve this programatically?

解决方案

Use routing in your global.asax file to change route from requested "

http://subdomain.domainName.org

" to "

http://domainName.org

"


这篇关于Windows服务器上的asp.net项目中的子域名网址的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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