database.php 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. <?php
  2. return [
  3. 'default' => [
  4. 'type' => 'MySQLi',
  5. 'connection' => [
  6. /**
  7. * MySQLi driver config information
  8. *
  9. * The following options are available for MySQLi:
  10. *
  11. * string hostname server hostname, or socket
  12. * string database database name
  13. * string username database username
  14. * string password database password
  15. * boolean persistent use persistent connections?
  16. * array ssl ssl parameters as "key => value" pairs.
  17. * Available keys: client_key_path, client_cert_path, ca_cert_path, ca_dir_path, cipher
  18. * array variables system variables as "key => value" pairs
  19. *
  20. * Ports and sockets may be appended to the hostname.
  21. *
  22. * MySQLi driver config example:
  23. *
  24. */
  25. 'hostname' => 'localhost',
  26. 'database' => 'koseven',
  27. 'username' => FALSE,
  28. 'password' => FALSE,
  29. 'persistent' => FALSE,
  30. 'ssl' => NULL,
  31. ],
  32. 'table_prefix' => '',
  33. 'charset' => 'utf8',
  34. 'caching' => FALSE,
  35. ],
  36. 'alternate' => [
  37. 'type' => 'PDO',
  38. 'connection' => [
  39. /**
  40. * The following options are available for PDO:
  41. *
  42. * string dsn Data Source Name
  43. * string username database username
  44. * string password database password
  45. * boolean persistent use persistent connections?
  46. */
  47. 'dsn' => 'mysql:host=localhost;dbname=koseven',
  48. 'username' => 'root',
  49. 'password' => 'r00tdb',
  50. 'persistent' => FALSE,
  51. ],
  52. /**
  53. * The following extra options are available for PDO:
  54. *
  55. * string identifier set the escaping identifier
  56. */
  57. 'table_prefix' => '',
  58. 'charset' => 'utf8',
  59. 'caching' => FALSE,
  60. ],
  61. ];