A client of ours has the following setup under IIS
Sites
- applications (binds to http://applications.domain.com)
- app1
- app2
app1
and app2
are both .NET Single Page Applications (combination of .NET MVC and .NET Web API).
The applications are under the C:\inetpub\applications\
folder and both have been converted to applications. Thus app1 is available under the following URL http://applications.domain.com/app1
and app2 is available under http://applications.domain.com/app2
The problem I'm running into is that all the AJAX routes are relative to the root (/) route and are therefore non existant e.g. http://applications.domain.com/api/products
doesn't throws a 404 since the route is actually http://applications.domain.com/app1/api/products
.
Is there an IIS setting that will allow me to make this work short of re-writing all my AJAX calls with the prefix? Or is there a different way I can configure this kind of setup under IIS? Thanks.