Welcome Guest, Not a member yet? Register   Sign In
saving custom functions
#1

[eluser]emrah[/eluser]
I have some database unrelated functions which I access frequently.
So I need a advice to place them in the codeigniter libray.

Model directory is for database related functions. So I think it is a bad choice for locating database unrelated functions.

libraries, helpers or another..
which directory is the best for MVC structure.


thanks...
#2

[eluser]Madmartigan1[/eluser]
[quote author="emrah" date="1293486357"]I have some database unrelated functions which I access frequently.
So I need a advice to place them in the codeigniter libray.

Model directory is for database related functions. So I think it is a bad choice for locating database unrelated functions.

libraries, helpers or another..
which directory is the best for MVC structure.


thanks...[/quote]

Group related functions into a library, anything left over can simply go into a helper.
#3

[eluser]emrah[/eluser]
with 'group related' what you mean?
#4

[eluser]Madmartigan1[/eluser]
"Group" as a verb and "related" as an adjective. It DOES sound confusing what I said so here's another version:

Take all your functions that are directly related to each other, and put them in a library.
Put the rest of your functions in helper files.

Smile
#5

[eluser]emrah[/eluser]
Now I got it clearly.
My functions are on their way to helpers.

Smile

And also thanks for the grammar Wink




Theme © iAndrew 2016 - Forum software by © MyBB