CodeIgniter Forums
database connection using remote settings - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: database connection using remote settings (/showthread.php?tid=42229)



database connection using remote settings - El Forum - 05-31-2011

[eluser]vickatg[/eluser]
hello everyone

my problem is accessing a remote database with codeigniter, the settings used in the database.php file are correct because with the same settings i can access the database direct via my web browser.
what could be the problem?

current settings file
Code:
$db['default']['hostname'] = 'mysql-m.sourceforge.net';
$db['default']['username'] = 'root';
$db['default']['password'] = 'root';
$db['default']['database'] = 'myproject';
$db['default']['dbdriver'] = 'mysql';
$db['default']['dbprefix'] = '';
$db['default']['pconnect'] = TRUE;
$db['default']['db_debug'] = TRUE;
$db['default']['cache_on'] = FALSE;
$db['default']['cachedir'] = '';
$db['default']['char_set'] = 'utf8';
$db['default']['dbcollat'] = 'utf8_general_ci';
$db['default']['swap_pre'] = '';
$db['default']['autoinit'] = TRUE;
$db['default']['stricton'] = FALSE;