Welcome Guest, Not a member yet? Register   Sign In
CI 2.0 - Unable to extend library
#1

[eluser]Unknown[/eluser]
I am currently having trouble extending the input library.

Code:
class MY_Input extends CI_Input {

    function MY_Input()
    {
        parent::CI_Input();
    }
}

MY_Input.php is placed in application/libraries

Inside the class I have a function named: postarray()

When I call to $this->input->postarray() I get this error:
Code:
Call to undefined method CI_Input::postarray()

It looks like only the core functions from CI_Input is loaded and not the ones in MY_Input. Anyone got any hints?
#2

[eluser]Eric Barnes[/eluser]
Place it in application/core instead of application/libraries
#3

[eluser]Madmartigan1[/eluser]
use php5 constructor as well




Theme © iAndrew 2016 - Forum software by © MyBB