Welcome Guest, Not a member yet? Register   Sign In
Get automatic 3rd domain level
#1

[eluser]Unknown[/eluser]
Hi,
I need to assign a third-level domain (like: http://user-name.mysite.com) for each user registered on my web-site at registration form.

Can codeigniter support this? What i have to do to make this automatic?

Can i not use .htaccess?

Thanks!
#2

[eluser]rogierb[/eluser]
Do a google on wildcard subdomains. This is not so much Codeigniter specific. Once you got the wildcards working, route them to you default controller
#3

[eluser]Unknown[/eluser]
yes you can do it.
need to do some changes in route files. Save your user-name in db and force user to enter username before domain name. and check it in route file. It is easiest method to achieve your goal
#4

[eluser]PhilTem[/eluser]
[quote author="rogierb" date="1255443800"]Do a google on wildcard subdomains. This is not so much Codeigniter specific. Once you got the wildcards working, route them to you default controller[/quote]

@RogierB is right: It's more an apache2/webserver issue than something specifically related to CI. You will need to set up widlcard subdomains which then will point to something like

Code:
http://www.example.com/users/profile/<user-name>




Theme © iAndrew 2016 - Forum software by © MyBB