First time when user runs my application i want to set database details as entered by the user in my application.
Please let me know how i can edit config/database.php f
If you want to set the database connection dynamically for just one request you can also use the following option.
Config::set('database.connections.local.host', '');
Config::set('database.connections.local.database', '');
Config::set('database.connections.local.username', '');
Config::set('database.connections.local.password', '');
Your DB config can looks like this in that case, or just provide default connection information and override it via the above commands.
'connections' => array(
'local' => array(
'driver' => 'mysql',
'host' => '',
'database' => '',
'username' => '',
'password' => '',
'charset' => 'utf8',
'collation' => 'utf8_unicode_cli',
'prefix' => '',
),
),