Welcome Guest, Not a member yet? Register   Sign In
using codeigniter instance in different php
#1

[eluser]xeroblast[/eluser]
how do i include the database wrapper of codeigniter in my different php files?

www.example.com/ci -> using codeigniter

www.example.com/other -> using standard php (no framework)

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

i.e
Code:
<?php
include(codeigniter_database_wrapper);
$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.
#2

[eluser]xeroblast[/eluser]
i have found this and this is what i wanted. thanks..

http://hasin.me/2007/06/13/using-activer...deigniter/




Theme © iAndrew 2016 - Forum software by © MyBB