I have a question that I couldn’t find the answer because I don’t know how to search it in English 🙂
How can I let my customers have their own domains redirect to my server and identify them? Like WordPress.
For example, I have created a simple CMS system and customers can register and have their own pages like john.mysite.com. But if they want to use their domains, do I have to create all of those domains on Plesk? By the way, I’m using IIS 7.5 with Plesk.
I also don’t want to use iframe.
Example;
john.mywebsite.com/categories-150.html –>
www.johnswebsite.com/categories-150.html
But it should be using the same code. I shouldn’t have to copy all the source codes and create seperate domains for this purpose.
For sure, I can make them change their ns to my server and specify an A record but how can I identify it by code? (C# ASP.NET MVC) I assume I can search for the domain name over database and get the ID but how can I pass the domain name?
I hope you can understand 🙂
Thanks and regards
2
Answers
Your Question is not to clear to me, but ima try to help you
first you need to change DNS settings and point to your IP
then in iis you make a site and add that domain as the hostheader
and to get the requested url ou can use
for more info on server variables
http://msdn.microsoft.com/en-us/library/ms524602(v=vs.90).aspx
As I see it, it is some string manipulation and using a dictionary to get what you want.
E.g.:
Or do you mean something different?