New Project\")." />
开发者

ASP.NET MVC and ApplicationPath

开发者 https://www.devze.com 2022-12-18 05:23 出处:网络
Question is about paths and domains: I have an out-of-the box ASP.NET MVC project (generated by \"File->New Project\").

Question is about paths and domains:

I have an out-of-the box ASP.NET MVC project (generated by "File->New Project").

On LogOn page it does: return Redirect("~/Account开发者_如何学编程/LogOn");.

I have a domain name: mycompany.com, and following file structure on the server:

/Root
  /MyApp (this is where my app goes into)
     Default.aspx
     ...

I have set up following domain pointer: mycompany.com -> \MyApp

When I go to mycompany.com I get an error, something about can't find

mycompany.com/MyApp/MyApp/Account/LogOn

Question: Where does second /MyApp path element comes from?

Note: If I don't use domain pointer and deploy the site to the root - everything works just fine.

Note: My hosting provider is webhost4life.com.


Try "return Redirect("/Account/LogOn")" instead.

0

精彩评论

暂无评论...
验证码 换一张
取 消