I need to connect to a DB that's name will be entered in the URL. For Example the URL will be
http://my_url.com/comp/login
So the DB I need to connect to is 'comp'.
Is there a way to do this without defining each database in the database.php config file?
something like
define('COMP', $this -> uri -> segment(1));
and then
'database' => 'tm_'.COMP,
The above gives me an error about the $this, so I am not completely sure where I can define the COMP variable where the database config file can read it.
Thanx