Skip to content
jrbasso edited this page Sep 13, 2010 · 2 revisions

To install, clone this project on you plugins directory:
git clone git://github.com/jrbasso/array_datasource.git app/plugins/array_datasource

After this, you need create a new connection on your app/config/databases.php_. On this file, create a new connection with any name and configuration with datasource ArrayDatasource.ArraySource. See the result:

class DATABASE_CONFIG {
	var $default = array(
		'driver' => 'mysql',
		'persistent' => false,
		'host' => 'localhost',
		'login' => 'user',
		'password' => 'password',
		'database' => 'database_name',
		'prefix' => '',
	);
	var $local = array(
		'datasource' => 'ArrayDatasource.ArraySource'
	);
	var $test = array(
		'driver' => 'mysql',
		'persistent' => false,
		'host' => 'localhost',
		'login' => 'user',
		'password' => 'password',
		'database' => 'test_database
name’,
‘prefix’ => ’’,
);
}
?>

The name ‘local’ can be changed.

Clone this wiki locally