• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Calling functions inside library

#1
[eluser]Unknown[/eluser]
I have a library looking like this

class Anylibrary {
private $CI;

public function __construct()
{

$this->CI =& get_instance();


}

public function test()
{

echo $this->CI->hello();

}

public function hello() {

return "hello world";
}

}


I am not able to call function Hello from inside function test. Any ideas why?





Messages In This Thread
Calling functions inside library - by El Forum - 09-23-2011, 10:56 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.