简体   繁体   English

使用asp.net mvc的特定于客户端的动态URL

[英]Client Specific Dynamic Urls with asp.net mvc

I'm building an app and within the app clients will be allowed to have many specific urls for themselves that they can add to their own sub domain. 我正在构建一个应用程序,在该应用程序内,客户端将被允许拥有许多特定的URL,它们可以添加到自己的子域中。

So for instance they'll have a subdomain and have a monthly competition. 因此,举例来说,他们将拥有一个子域并每月进行一次竞争。

subdomain.client1.com/myJuneComp/ subdomain.client1.com/myJuneComp/

subdomain.client1.com/myJuneComp/thankyou subdomain.client1.com/myJuneComp/thankyou

subdomain.client1.com/myJulyComp/ subdomain.client1.com/myJulyComp/

subdomain.client1.com/myJulyComp/thankyou subdomain.client1.com/myJulyComp/thankyou

subdomain.client1.com/randomComp subdomain.client1.com/randomComp

subdomain.client1.com/randomComp/thankyou subdomain.client1.com/randomComp/thankyou

I'm wondering what the best way to implement this in asp.net mvc would be. 我想知道在asp.net mvc中实现此的最佳方法是什么。 It will also be mixed with the application administration. 它还将与应用程序管理混合在一起。

在您的客户端操作中添加一个参数(例如, string clientName ),然后将{clientName}/添加到每个相关路由URL的开头。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM