CodeIgniter Forums

Full Version: using codeigniter instance in different php
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

how do i include the database wrapper of codeigniter in my different php files? -> using codeigniter -> using standard php (no framework)

i want to use the codeigniter database wrapper in my 'other' directory?

$db = new Codeigniter_database_wrapper();
$query = $db->get('my_table');
$result = $query->result();
something like this...

thanks in advance...

p.s. : i want to use this because some people in the company i am working dont know much about frameworks so i'll just want them to use their current php skills and all their database queries are pass in this extended php class file.

El Forum

i have found this and this is what i wanted. thanks..