• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
forms in my model?

#4
[eluser]NogDog[/eluser]
[quote author="ixxalnxxi" date="1230977995"]To make it into a CI helper function, I make a Helper class in the helper directory and just add the function there, correct?[/quote]
Yes, or alternatively you could extend an existing helper. For instance, if you're already using the HTML helper, you could just create a "MY_html_helper.php" file in your system/application/helpers directory and define the function there. Then when you do your "$this->load->helper('html');", it will include your new function with it.

It may not be a pure OOP solution, but it would seem pretty clean, simple, and efficient to me.


Messages In This Thread
forms in my model? - by El Forum - 01-02-2009, 09:56 PM
forms in my model? - by El Forum - 01-02-2009, 10:14 PM
forms in my model? - by El Forum - 01-02-2009, 10:19 PM
forms in my model? - by El Forum - 01-02-2009, 10:45 PM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.