Helper files

If you ask me its more logical to use static functions instead of normal functions, just like you said rand could be for example math -> rand or sort -> rand.

But if I don't use static functions and if I didn't write all of the app I wouldn't know if the function rand is for sorting or for math, if it was static I would be able to call Sort:: and get available helper functions for sorting.

But after all PHP is built in the same way as the helper functions in CI, if you want a random number you call rand() and not Math::rand().

Messages In This Thread
Helper files - by El Forum - 04-20-2010, 06:14 AM
Helper files - by El Forum - 04-20-2010, 06:33 AM
Helper files - by El Forum - 04-21-2010, 02:50 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

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