Welcome Guest, Not a member yet? Register   Sign In
Codeigniter - passing multiple data arrays to a view?
#2

[eluser]Simian Studios[/eluser]
Hi Dan

$data should just be an array, so this should work:

Code:
$data['arr'] = $arr;
$this->template->load('admin/template', 'admin/eventEdit', $data);

Then in your view you would access $arr via "$data['arr']" and treat it just like a normal array.

I would suggest giving $arr a more descriptive name also, just to avoid confusion further down the line..


Messages In This Thread
Codeigniter - passing multiple data arrays to a view? - by El Forum - 06-24-2010, 07:32 AM
Codeigniter - passing multiple data arrays to a view? - by El Forum - 06-24-2010, 07:54 AM



Theme © iAndrew 2016 - Forum software by © MyBB