fix
This commit is contained in:
@@ -59,7 +59,8 @@ $autoload['packages'] = array();
|
||||
| $autoload['libraries'] = array('user_agent' => 'ua');
|
||||
*/
|
||||
//$autoload['libraries'] = array();
|
||||
$autoload['libraries'] = array('session','form_validation');
|
||||
//$autoload['libraries'] = array('session','form_validation');
|
||||
$autoload['libraries'] = array('database','session','form_validation');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Drivers
|
||||
|
||||
@@ -73,7 +73,32 @@ defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
$active_group = 'default';
|
||||
$query_builder = TRUE;
|
||||
|
||||
global $coregrade;
|
||||
|
||||
$db['default'] = array(
|
||||
'dsn' => '',
|
||||
'hostname' => $coregrade->cfgReadChar('database.host'), /* '10.142.0.10', */
|
||||
'username' => $coregrade->cfgReadChar('database.user'), /* 'savvy', */
|
||||
'password' => $coregrade->cfgReadChar('database.pass'), /* 'savvy001!', */
|
||||
'database' => $coregrade->cfgReadChar('database.name'), /* 'savvy', */
|
||||
'dbdriver' => 'postgre',
|
||||
'dbprefix' => '',
|
||||
'pconnect' => FALSE,
|
||||
'db_debug' => (ENVIRONMENT !== 'production'),
|
||||
'cache_on' => FALSE,
|
||||
'cachedir' => '',
|
||||
'char_set' => 'utf8',
|
||||
'dbcollat' => 'utf8_general_ci',
|
||||
'swap_pre' => '',
|
||||
'encrypt' => FALSE,
|
||||
'compress' => FALSE,
|
||||
'stricton' => FALSE,
|
||||
'failover' => array(),
|
||||
'save_queries' => TRUE
|
||||
);
|
||||
|
||||
|
||||
$db['defaultBAK'] = array(
|
||||
'dsn' => '',
|
||||
'hostname' => 'localhost',
|
||||
'username' => '',
|
||||
|
||||
@@ -7,6 +7,13 @@ class Member extends Member_Controller {
|
||||
public function index() {
|
||||
|
||||
$data = array();
|
||||
|
||||
$mysql = "SELECT * FROM members_pages WHERE member_id =5";
|
||||
$r = $this->db->query($mysql);
|
||||
$f = $r->row_array();
|
||||
|
||||
|
||||
|
||||
$this->renderMemberPages('view_dash', $data);
|
||||
}
|
||||
|
||||
@@ -15,6 +22,4 @@ class Member extends Member_Controller {
|
||||
$this->renderMemberPages('view_mycalendar', $data);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
if (!array_key_exists('coregrade', $GLOBALS)) {
|
||||
$coregrade = new coregrade_api_oameye\coregrade();
|
||||
|
||||
$USER = $_SERVER['SCRIPT_FILENAME'];
|
||||
$USER = str_replace('/home', '', $USER);
|
||||
$USER = strtok($USER, '/');
|
||||
if ($USER=='opt') $USER = 'root';
|
||||
// Load API class
|
||||
/* $USER="savvy";
|
||||
$savvyext_class = 'savvyext_api_' . $USER . '\\SavvyExt';
|
||||
$savvyext = new $savvyext_class();
|
||||
*/
|
||||
|
||||
$coregrade_class = 'coregrade_api_' . $USER . '\\coregrade';
|
||||
if (!is_object($coregrade)) {
|
||||
$coregrade = new $coregrade_class();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -312,4 +312,7 @@ switch (ENVIRONMENT)
|
||||
*
|
||||
* And away we go...
|
||||
*/
|
||||
|
||||
require_once 'backend.php';
|
||||
|
||||
require_once BASEPATH.'core/CodeIgniter.php';
|
||||
|
||||
Reference in New Issue
Block a user