LiveUser
[ class tree: LiveUser ] [ index: LiveUser ] [ all elements ]

Source for file conf.php

Documentation is available at conf.php

  1. <?php
  2. // BC hack
  3. if (!defined('PATH_SEPARATOR')) {
  4.     if (defined('DIRECTORY_SEPARATOR'&& DIRECTORY_SEPARATOR == "\\"{
  5.         define('PATH_SEPARATOR'';');
  6.     else {
  7.         define('PATH_SEPARATOR'':');
  8.     }
  9. }
  10.  
  11. // set this to the path in which the directory for liveuser resides
  12. // more remove the following two lines to test LiveUser in the standard
  13. // PEAR directory
  14. //$path_to_liveuser_dir = './pear/'.PATH_SEPARATOR;
  15. //ini_set('include_path', $path_to_liveuser_dir.ini_get('include_path'));
  16.  
  17. // Data Source Name (DSN)
  18. //$dsn = '{dbtype}://{user}:{passwd}@{dbhost}/{dbname}';
  19. $dsn 'mysql://root:@localhost/pear_test';
  20.  
  21. $liveuserConfig = array(
  22.     'session'           => array('name' => 'PHPSESSID','varname' => 'loginInfo'),
  23.     'login'             => array('username' => 'handle''password' => 'passwd''remember' => 'rememberMe'),
  24.     'logout'            => array('trigger' => 'logout''destroy'  => true'method' => 'get'),
  25.     'cookie'            => array('name' => 'loginInfo''path' => '/''domain' => '''lifetime' => 30'secret' => 'mysecretkey'),
  26.     'autoInit'          => true,
  27.     'authContainers'    => array(0 => array(
  28.         'type' => 'DB',
  29.                   'dsn' => $dsn,
  30.                   'loginTimeout' => 0,
  31.                   'expireTime'   => 0,
  32.                   'idleTime'     => 0,
  33.                   'allowDuplicateHandles'  => 1,
  34.                   'passwordEncryptionMode' => 'PLAIN',
  35.                   'authTableCols' => array(
  36.                       'required' => array(
  37.                           'auth_user_id' => array('name' => 'auth_user_id''type' => ''),
  38.                           'handle'       => array('name' => 'handle',       'type' => ''),
  39.                           'passwd'       => array('name' => 'passwd',       'type' => ''),
  40.                       ),
  41.                       'optional' => array(
  42.                           'lastlogin'    => array('name' => 'lastlogin',    'type' => ''),
  43.                           'is_active'    => array('name' => 'is_active',    'type' => '')
  44.                       )
  45.                     )
  46.     )
  47.                                 ),
  48.     'permContainer' => array(
  49.         'type'   => 'DB_Complex',
  50.         'dsn' => $dsn,
  51.         'prefix' => 'liveuser_'
  52.                 )
  53. );
  54.  
  55. // Get LiveUser class definition
  56. require_once 'LiveUser.php';

Documentation generated on Mon, 11 Mar 2019 13:51:49 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.