Welcome Guest, Not a member yet? Register   Sign In
Database Connection
#1

<?php
defined('BASEPATH') OR exit('No direct script access allowed');

$active_group = 'default';
$query_builder = TRUE;

$db['default'] = array(
    'dsn'   => '',
    'hostname' => '192.168.1.55',
    'username' => 'sa',
    'password' => 'admin1234',
    'database' => 'MyDatabase',
    'dbdriver' => 'sqlsrv',
    'dbprefix' => '',
    'pconnect' => TRUE,
    '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
);

this is my database connection and working fine...

but when i copy folder to run at another computer it's now working


error :
unable to connect to your database server using the provided setting.

i try to change
    'db_debug' => FALSE,


it's working but some CI function not working
like  : num_rows() , etc..

i use xampp, and sql server database
Reply


Messages In This Thread
Database Connection - by amansusanto - 04-21-2019, 08:01 PM
RE: Database Connection - by DELE - 04-21-2019, 08:22 PM
RE: Database Connection - by amansusanto - 04-21-2019, 08:27 PM
RE: Database Connection - by DELE - 04-21-2019, 09:06 PM
RE: Database Connection - by amansusanto - 04-21-2019, 10:43 PM
RE: Database Connection - by amansusanto - 04-22-2019, 12:08 AM
RE: Database Connection - by InsiteFX - 04-22-2019, 04:31 AM



Theme © iAndrew 2016 - Forum software by © MyBB