Welcome Guest, Not a member yet? Register   Sign In
Usernames as subdomains and a root website
#1

[eluser]whizzer[/eluser]
Hello forum,
I'm trying to make a website like blogger where every registration would be is subdomain-style. I used that method and evrything works. But now i have a problem. I need to accomplish several things:
1. Check for a valid username. Before the controller with the user template, content and etc is loaded I need to make sure that the username is valid. For example bad.username.blogger.com is not valid and should lead to the 404 page. Also if there isn't a registered user with that username.
2. Load the default website. When blogger.com (just an example url) is opened, there is no username (hence the username is an empty string '') and I should load the default website.
3. Do 1 and 2 before the main controller is loaded, so when I load it for the first time I will know what the username is (or a blank one for the root website) and load the corresponding theme, content, etc.
I'm also accepting ideas for a directory structure. There will be the templates for my root website as well as the templates for my users blogs.
Thank you.
Smile


Messages In This Thread
Usernames as subdomains and a root website - by El Forum - 07-24-2010, 02:53 PM
Usernames as subdomains and a root website - by El Forum - 07-24-2010, 07:27 PM
Usernames as subdomains and a root website - by El Forum - 07-28-2010, 05:29 AM
Usernames as subdomains and a root website - by El Forum - 07-28-2010, 05:43 AM
Usernames as subdomains and a root website - by El Forum - 07-28-2010, 08:14 AM
Usernames as subdomains and a root website - by El Forum - 07-28-2010, 09:03 AM
Usernames as subdomains and a root website - by El Forum - 07-28-2010, 09:19 AM
Usernames as subdomains and a root website - by El Forum - 07-28-2010, 09:55 AM
Usernames as subdomains and a root website - by El Forum - 07-28-2010, 12:16 PM
Usernames as subdomains and a root website - by El Forum - 07-28-2010, 12:29 PM
Usernames as subdomains and a root website - by El Forum - 07-29-2010, 03:23 AM
Usernames as subdomains and a root website - by El Forum - 08-11-2010, 05:54 AM



Theme © iAndrew 2016 - Forum software by © MyBB