Welcome Guest, Not a member yet? Register   Sign In
Custom Validation Function
#7

(This post was last modified: 09-30-2015, 06:42 AM by Martin7483.)

(09-30-2015, 03:13 AM)ardavan Wrote:
(09-30-2015, 02:37 AM)Martin7483 Wrote: Where in your controller are you loading the helper? If you are loading it in a _constructor you must call parent::__constructor like so:



PHP Code:
public function __constructor() {
 
   parent::__constructor();

 
   $this->load->helper('validation');

and load resources after this call else the helper or any resource you try to load will not be assigned to the CI super object

Mine is also the same. I written in my construct function.
but i can see you written here constructor() instead of construct() !
is it true? i never seen contractor in CI. make me correct if I'm wrong.

Thanks for reply

Sorry! That was a typo... It must be:
PHP Code:
public function __construct() {
 
   parent::__construct();
 
   $this->load->helper('validation');


The darn things are called constructors. But thats not what you place in your classes Tongue

Anyway, you say you are doing things this way in your controller?
Reply


Messages In This Thread
Custom Validation Function - by ardavan - 09-22-2015, 06:28 AM
RE: Custom Validation Function - by kilishan - 09-22-2015, 06:52 AM
RE: Custom Validation Function - by ardavan - 09-24-2015, 06:10 PM
RE: Custom Validation Function - by ardavan - 09-30-2015, 02:15 AM
RE: Custom Validation Function - by Martin7483 - 09-30-2015, 02:37 AM
RE: Custom Validation Function - by ardavan - 09-30-2015, 03:13 AM
RE: Custom Validation Function - by Martin7483 - 09-30-2015, 03:39 AM
RE: Custom Validation Function - by Martin7483 - 09-30-2015, 07:22 AM



Theme © iAndrew 2016 - Forum software by © MyBB