I need to pass the $params var to the MY_Model constructor, isn't it? I'm doing it as follows: parent::__construct($table, $params); // table name But this code throws this error:
Ok, now it's working for me, I was passing the "required" parameter as string. Your fix works well, but is needed to pass the "$params" var to the "MY_Model" constructor
The fix that was put in place was to check if the $params was a string, it would assume you are passing the module name (which is what the previous version was looking for). If the parameters was an array, then it would send it as initialization parameters.
I'm not sure if I understand what you mean "Your fix works well, but is needed to pass the "$params" var to the "MY_Model" constructor". Could you help clarify, just in case there is a better way for me to implement the fix? Thanks.
Sorry about my writing, my English is not enough fluent... I mean the "base_module_model" constructor code should finish with "parent::__construct($table, $params); // table name, params" instead of "parent::__construct($table); //table name"
You are right, I usually go sleep late working on my own projects. I'm doing my new personal webpage with FuelCMS and I'm planning to release the code with Github (I have some files right now, but in an early stage, because I'm making continuous changes while I'm learning). I want to thank you all your efforts because you are doing a really good product. I'm loving the half framework half CMS idea!
Comments
Thank you very much. Have a nice day!
I'm doing it as follows: parent::__construct($table, $params); // table name
But this code throws this error:
Severity: Notice
Message: Undefined variable: required
Filename: libraries/MY_Model.php
Line Number: 1665
Your fix works well, but is needed to pass the "$params" var to the "MY_Model" constructor
I'm not sure if I understand what you mean "Your fix works well, but is needed to pass the "$params" var to the "MY_Model" constructor". Could you help clarify, just in case there is a better way for me to implement the fix? Thanks.
I mean the "base_module_model" constructor code should finish with
"parent::__construct($table, $params); // table name, params"
instead of
"parent::__construct($table); //table name"
Hope I can help you...
Are your working at 2:45am????
You are insane!!!