class member function in function?

frins

New Member
So i have this class that includes some custom functions named class.phpI have another file called config.php that includes\[code\]require('engine.class.php');$engine = new engine;\[/code\]config.php also requires functions.php to run like:\[code\]require('functions.php');\[/code\]i have a function in functions.php that uses $engine eg:\[code\]function login($username, $password){ return $engine->mysql_query('SELECT `user_id` WH...', 'array);//this is custom function in class.php}\[/code\]but when i run the page that reuires config.php i get some error like:\[code\]Fatal error: Call to a member function mysql_query() on a non-object in ../somedir/functions.php on line 3\[/code\]
 
Back
Top