I have a project that contains 2 web application and I want to use same URL to access the two application
1) admin site used by company : appcompany.com
2) general site used by company's customers : [CUSTOMER_ID].appcompany.com
Currently, typing appcompany.com in the browser takes you to the home page indicating no customer specified
Typing 123.appcompany.com takes you to a page customized for customer 123.
As said earlier, the general site application can determine when no customer was specified and could redirect - but redirecting to the admin site may require another URL since they are different project
The problem is I don't know how to make appcompany.com go to the admin site without having 2 URL(s).
UPDATE
I am using asp.net ROUTING to simulate sub-domain routing in case I don't have privilege to multiple physical sub-domains
You need to specify it in IIS adminitrator. You need to create 2 different applications:
Each of this one have to point to the physical directory where you implement your applications.
Then you have to edit the bindings:
IIS will redirect each request to the specified app: You should add the binding for each company in the same moment where you add the DNS entry for it.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.