[eluser]TWP Marketing[/eluser]
[quote author="AMCerasoli" date="1347557228"]I'm just starting with CI, I have placed the file MY_Form_validation.php in applications/libraries and then as the user guide says I have just load normally the library
Code:
$this->load->library('form_validation');
. B
But I'm getting: Fatal error: Call to undefined method CI_Form_validation::CI_Form_validation() in /web/htdocs/www.website.com/home/application/libraries/MY_Form_validation.php on line 50
Am I doing something wrong? thanks.
Good extension BTW. :-)[/quote]
First, you're responding to a thread that is two years old, which means it was written for an older version of CI. Which version are you using?
I assume you are EXTENDING the CI form validation library and not writing your own?
Show us your code in MY_Form_validation.php, specifically look at line 50 and at the class declaration at the top of MY_Form_validation.php which should extend CI_Form_validation like this:
Code:
class MY_Form_validation extends CI_Form_validation {
Check your config/config.php and be sure this line is present:
Code:
...
$config['subclass_prefix'] = 'MY_';
...