Welcome Guest, Not a member yet? Register   Sign In
Global variables, set defined variables
#2

[eluser]Colin Williams[/eluser]
Code:
$data["foo"][] = "test";
$data["foo"][] = "test1";

That ought to work. It will be $foo[0] and $foo[1] in your view.

If I'm going to be sharing variable throughout different areas of an application, I'll usually just create a config file for it and load it with the Config class.


Messages In This Thread
Global variables, set defined variables - by El Forum - 07-15-2008, 01:01 PM
Global variables, set defined variables - by El Forum - 07-15-2008, 02:37 PM



Theme © iAndrew 2016 - Forum software by © MyBB