Subversion Repositories SmartDukaan

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
13532 anikendra 1
<?php
2
/**
3
 *
4
 *
5
 * @link          http://cakephp.org CakePHP(tm) Project
6
 * @package       app.Config
7
 * @since         CakePHP(tm) v 0.2.9
8
 */
9
 
10
/**
11
 * Database configuration class.
12
 * You can specify multiple configurations for production, development and testing.
13
 *
14
 * datasource => The name of a supported datasource; valid options are as follows:
15
 *  Database/Mysql - MySQL 4 & 5,
16
 *  Database/Sqlite - SQLite (PHP5 only),
17
 *  Database/Postgres - PostgreSQL 7 and higher,
18
 *  Database/Sqlserver - Microsoft SQL Server 2005 and higher
19
 *
20
 * You can add custom database datasources (or override existing datasources) by adding the
21
 * appropriate file to app/Model/Datasource/Database. Datasources should be named 'MyDatasource.php',
22
 *
23
 *
24
 * persistent => true / false
25
 * Determines whether or not the database should use a persistent connection
26
 *
27
 * host =>
28
 * the host you connect to the database. To add a socket or port number, use 'port' => #
29
 *
30
 * prefix =>
31
 * Uses the given prefix for all the tables in this database. This setting can be overridden
32
 * on a per-table basis with the Model::$tablePrefix property.
33
 *
34
 * schema =>
35
 * For Postgres/Sqlserver specifies which schema you would like to use the tables in. Postgres defaults to 'public'. For Sqlserver, it defaults to empty and use
36
 * the connected user's default schema (typically 'dbo').
37
 *
38
 * encoding =>
39
 * For MySQL, Postgres specifies the character encoding to use when connecting to the
40
 * database. Uses database default not specified.
41
 *
42
 * unix_socket =>
43
 * For MySQL to connect via socket specify the `unix_socket` parameter instead of `host` and `port`
44
 
45
 * settings =>
46
 * Array of key/value pairs, on connection it executes SET statements for each pair
47
 * For MySQL : http://dev.mysql.com/doc/refman/5.6/en/set-statement.html
48
 * For Postgres : http://www.postgresql.org/docs/9.2/static/sql-set.html
49
 * For Sql Server : http://msdn.microsoft.com/en-us/library/ms190356.aspx
50
 */
51
class DATABASE_CONFIG {
52
 
53
	public $default = array(
54
		'datasource' => 'Database/Mysql',
55
		'persistent' => false,
56
		'host' => 'localhost',
57
		'login' => 'user',
58
		'password' => 'password',
59
		'database' => 'database_name',
60
		'prefix' => '',
61
		//'encoding' => 'utf8',
62
	);
63
 
64
	public $test = array(
65
		'datasource' => 'Database/Mysql',
66
		'persistent' => false,
67
		'host' => 'localhost',
68
		'login' => 'user',
69
		'password' => 'password',
70
		'database' => 'test_database_name',
71
		'prefix' => '',
72
		//'encoding' => 'utf8',
73
	);
74
}