CodeIgniter Forums

Full Version: Subdomain configuration?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi all

Appreciate this has been covered a few times here and there, but I've tried several solutions and nothing seems to be working for me - so any guidance would be really appreciated!

I'm trying to keep things somewhat easy to maintain for myself with shared config and models etc. I have several parts to my CodeIgniter setup which would be accessed through a subdomain, but internally would just be a controller folder. For example:
  • admin.domain.com --> domain.com/admin

  • users.domain.com --> domain.com/users

  • users.domain.com/my-account --> domain.com/users/my-account

  • accounts.domain.com --> domain.com/accountshttps://omegle.onl/ vshare

Each of these subdomains are fixed (it's not a wildcard subdomain), but the only way I've figured out how to do this with CodeIgniter is point them all at the same directory and basically route based on htaccess rewrites to the index.php file, seems they're all controller folders (routes also plays a part in this) - although I'm very much open to better suggestions.