Welcome Guest, Not a member yet? Register   Sign In
Global Variables from database
#2

[eluser]Crafter[/eluser]
I'm tempted to say use PHP global variables, but this might not be best practice. That option is always there, provide you exercise restraint and take car not to overload memory with global variables.

Typically, in the MVC framework, your data will flow like this:
(request by controller) -> model -> controller -> view/library/,,/ -> (response to controller)

So ultimately, your controller should keep a copy of the config variables and pass it to views, libraries and so on as required.


Messages In This Thread
Global Variables from database - by El Forum - 01-11-2008, 12:03 PM
Global Variables from database - by El Forum - 01-11-2008, 02:15 PM
Global Variables from database - by El Forum - 01-11-2008, 03:17 PM
Global Variables from database - by El Forum - 01-11-2008, 05:32 PM
Global Variables from database - by El Forum - 01-12-2008, 04:11 AM



Theme © iAndrew 2016 - Forum software by © MyBB