Welcome Guest, Not a member yet? Register   Sign In
Settings Library
#7

[eluser]PhilTem[/eluser]
Regarding double instantation of a library: If you load the class via the CI-loader class, then you won't have problems with doubled stuff like the items. But if you loaded the class via include and new then you better watch our for doubled items (keyword singleton). I think you can workaround with using static variables holding your setting-items because static variables only get populated once Wink
Even though I'm not quite sure if it'll help.
Therefore better load library via either $autoload['libraries'] in or $this->load->library(); so there will only be one instance of it.

Have you considered caching the config-values? I'm not quite sure if it's really sensible to do it in terms of speed with getting all results from the db vs. reading the cache-file. What do others think?^^


Messages In This Thread
Settings Library - by El Forum - 02-01-2012, 04:31 AM
Settings Library - by El Forum - 02-01-2012, 07:12 AM
Settings Library - by El Forum - 02-01-2012, 09:10 AM
Settings Library - by El Forum - 02-01-2012, 11:14 PM
Settings Library - by El Forum - 02-02-2012, 12:54 AM
Settings Library - by El Forum - 02-02-2012, 02:01 AM
Settings Library - by El Forum - 02-02-2012, 02:35 AM
Settings Library - by El Forum - 02-02-2012, 07:33 AM
Settings Library - by El Forum - 02-02-2012, 08:29 AM
Settings Library - by El Forum - 02-03-2012, 11:21 PM
Settings Library - by El Forum - 02-03-2012, 11:58 PM
Settings Library - by El Forum - 02-04-2012, 01:10 AM
Settings Library - by El Forum - 02-04-2012, 02:34 AM



Theme © iAndrew 2016 - Forum software by © MyBB