Forum Moderators: phranque

Message Too Old, No Replies

Subdomain redirect for all users on my website?

         

Xinil

10:51 pm on Apr 1, 2006 (gmt 0)



Hey everyone. I'm new here. Glad to be a part of the forums. Got an interesting question I think.

Basically, I have a website with members, where I want each member to "have" their own subdomain. For instance, I want each member to be able to go to their member page like this:

[user1.mydomain.com...]
or
[user2.mydomain.com...]

The member page should load the same .php page, but based on what user they put in, PHP should pull different information. so if it's:

[jason.mydomain.com...] PHP will pull all information for Jason

alternatively

[alex.mydomain.com,...] PHP will pull all information relative to Alex.

How can I use .htaccess rules to accomplish this for any people that sign onto my website? Or, is this not even possible? :( I know the PHP part, so I don't need help there.

<snip>

Hope this all makes sense. Thanks in advance. :)

[edited by: jdMorgan at 4:29 pm (utc) on April 2, 2006]
[edit reason] No URLs, please. See Terms of Service. [/edit]