Welcome Guest, Not a member yet? Register   Sign In
[solved] : controller functions calling from within fragment views, PHP4 -> PHP5
#1

[eluser]tomcode[/eluser]
Hi,

I used to call functions defined in the controller from within my views. Under PHP4 this works without any problems. Now I'm switching to PHP5 and I get:

Quote:Call to undefined method CI_Loader::insert_code()

in my Controller I've defined the function :
Code:
function insert_code()
{
    return 'Hi';
}

in the fragment view I call it with:
Code:
<?=$this->insert_code();?>

What to do ? I want to keep the function inside the controller (no helper or library loading)


Thanks, Thomas


Messages In This Thread
[solved] : controller functions calling from within fragment views, PHP4 -> PHP5 - by El Forum - 10-02-2007, 04:47 AM



Theme © iAndrew 2016 - Forum software by © MyBB