Link to home
Start Free TrialLog in
Avatar of Lee W, MVP
Lee W, MVPFlag for United States of America

asked on

Using clientname.companyname.com in place of www.companyname.com/app/index.asp?clientid=1234

I have a client with a web site that he needs to allow his clients a more "customized" look and feel.  For example, his clients can log in to his site and access their data at www.myclientssite.com/app/index.aspx?clientid=1234

BUT, he wants to give them a more personalized look (in part because these clients will be offering access to their portion of the web site to their clients.  So what he wants is some AUTOMATED way to myclientsclientname.myclientssite.com to respond synonymously with www.myclientssite.com/app/index.aspx?clientid=1234

Now my understanding of the technology (using ASP.NET and IIS 6) is that the only way to do this would be to give each client a DNS record and then check the header to see which client's data should be accessed.  But is there any other way?  Or any way to script the creation of the DNS record?  (They don't currently manage their own DNS on their server, but they could).

(I'm asking this on several sites as I need to ensure the broadest possible range of answers - but any answer I get that's not from here I'll post back for your information).
Avatar of nauman_ahmed
nauman_ahmed
Flag of United States of America image

First you will have to add * pointer in your DNS for your domain so that *.yourwebsite.com redirect to the main page of your web site. I recommend creating a domain such as *.profile.yourwebsite.com. So lets say you have configured your domain and when user type myclientsclientname.profile.myclientssite.com it will go to your default.aspx page. In default.aspx page you can parse the URL, retrieve the user information and then either redirect the user to www.myclientssite.com/app/index.aspx?clientid=1234 or perform some other operation.

HTH, Nauman.
Avatar of Lee W, MVP

ASKER

That just may help... can you link to any examples documenting this?  Specifically, adding the * record and what type of record it is?
ASKER CERTIFIED SOLUTION
Avatar of nauman_ahmed
nauman_ahmed
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
We have access to edit our own DNS and at worst, we should be able to contact that DNS host on how exactly to set this up.  But assume for the moment we are running MS DNS - how would this be setup?