Welcome Guest, Not a member yet? Register   Sign In
Problems importing facebook client library
#2

[eluser]igniteflow[/eluser]
Solved it, by putting

Code:
/*
| -------------------------------------------------------------------
|  Native Auto-load
| -------------------------------------------------------------------
|
| Nothing to do with config/autoload.php, this allows PHP autoload to work
| for controller types and some third-party libraries.
|
*/
function __autoload($class)
{
    if(strpos($class, 'CI_') !== 0)
    {
        $class = APPPATH . 'classes/'. $class . EXT;
        $lib = APPPATH . 'libraries/'. $class . EXT;

        if(file_exists($class))
        {
            include_once( $class );
        }

        else if(file_exists($lib))
        {
            include_once( $lib );
        }
    }
}

in config.php. I doubt this is the most efficient way of including a class in CI though, and would like to hear the best way to do it...
ps. the above method was posted by phil at stackflow


Messages In This Thread
Problems importing facebook client library - by El Forum - 03-04-2010, 05:52 AM
Problems importing facebook client library - by El Forum - 03-04-2010, 06:11 AM
Problems importing facebook client library - by El Forum - 08-09-2010, 11:05 AM



Theme © iAndrew 2016 - Forum software by © MyBB