[eluser]tmcw[/eluser]
Been noticing a weird pattern in CI.
I have a controller, and some content that will be the same over a few different pages (methods). So I have that in a different method, which runs a query, throws the result into $vars['events'] = $r. Then I load that into a template, like so: $o = $this->load->view('/event/list', $vars,true); and return $o.
The weird part is that, after I run this method in another controller ($data['event_list'] = $this->event_list()
The variable $data['events'] holds the same data as $vars['events'] did, and running a query that returns false doesn't replace that data with false.
Now, maybe this is intended behavior, but it seems to be rather unpredictable when you think of encapsulation and unintended consequences... there isn't a way to load a template with data, and then load another without the second being affected by the first?
Any ideas here?