views:

23

answers:

1

Please, write 1 example config connect database from localhost to godaddy. This is connect to database from files on server to server :

 var $default = array(
  'driver' => 'mysql',
  'persistent' => false,
  'host' => 'mysite.db.6650008.hostedresource.com',
  'login' => 'myaccount',
  'password' => 'password12',
  'database' => 'mysite',
  'prefix' => '',
 );

Now, i want to write 1 config from localhost to database on godaddy. please, help me.

A: 

You can't do it from localhost. Set up a database on localhost and create your application. Then upload the code to your host (FTP) and change database configuration to be able to access the hosted database.

You usually don't have access to a database from another host for security reasons.