hao can i routing subdomain? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: hao can i routing subdomain? (/showthread.php?tid=63061) |
hao can i routing subdomain? - Aloghli - 09-21-2015 hao can i routing subdomain? RE: hao can i routing subdomain? - Muzikant - 09-22-2015 Not from CodeIgniter. You can route only controllers of the domain/subdomain, where your system is installed or from where it is accessed. Read URI Routing section in the documentation. But maybe with a .htaccess file or by changing the server configuration it could be achievable, but it is just a hypotesis. Tell us, if you will find a solution. RE: hao can i routing subdomain? - Narf - 09-23-2015 Some things are simpler than they seem ... Code: // application/config/routes.php RE: hao can i routing subdomain? - Martin7483 - 09-23-2015 (09-23-2015, 05:00 AM)Narf Wrote: Some things are simpler than they seem ... Wouldn't this only work if your subdomain is pointing to the same root directory as your main domain? RE: hao can i routing subdomain? - Narf - 09-23-2015 (09-23-2015, 05:13 AM)Martin7483 Wrote:(09-23-2015, 05:00 AM)Narf Wrote: Some things are simpler than they seem ... Yes, but how else do you expect to be able to have domain-based routing within CI? RE: hao can i routing subdomain? - Martin7483 - 09-23-2015 (09-23-2015, 05:19 AM)Narf Wrote:(09-23-2015, 05:13 AM)Martin7483 Wrote:(09-23-2015, 05:00 AM)Narf Wrote: Some things are simpler than they seem ... I was asking because a subdomain by default points to it's own directory in the root of your hosting RE: hao can i routing subdomain? - mwhitney - 09-23-2015 (09-23-2015, 05:24 AM)Martin7483 Wrote: I was asking because a subdomain by default points to it's own directory in the root of your hosting This depends on your host, and in most cases it can be changed. You could also put a copy of the index.php file in each subdomain and modify each index.php file to point to the same directories for everything else, or you could setup separate application directories for each subdomain but share the system directory. RE: hao can i routing subdomain? - Aloghli - 09-30-2015 (09-23-2015, 05:00 AM)Narf Wrote: Some things are simpler than they seem ... this is a good one, but some controlller dosn't work |