11.08.2017 Views

codebright

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Databases 214<br />

1 'database' => __DIR__.'/path/to/database.sqlite',<br />

The username and password indexes can be used to provide access credentials for your database<br />

connection.<br />

1 'username' => 'dayle',<br />

2 'password' => 'emma_w4tson_is_hot',<br />

SQLite Databases<br />

Once again, SQLite databases are a bit different here. They don’t have credentials. You can<br />

ommit these indexes from an SQLite connection block.<br />

The next configuration index is is charset, it can be used to specify the default character set for a<br />

database connection.<br />

1 'charset' => 'utf8',<br />

SQLite Databases<br />

You guessed it! The SQLite database doesn’t support this option. Just leave this index out<br />

of the connection array.<br />

You can set the default database collation using the collation index.<br />

1 'collation' => 'utf8_unicode_ci',<br />

SQLite Databases<br />

Once again, SQLite chooses to be a unique snowflake. You don’t need to provide the<br />

character set or collation index for it.<br />

Finally, we have the prefix option, which can be used to add a common prefix to your database<br />

tables.<br />

1 'prefix' => '',

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!