Your passing the data and cache multiple times, you only need to pass it once.
always pass the data in the first view, then it is available to all other views.
Try this, it's how I load the views.
PHP Code:
$view_cache = ['cache' => nn, 'cache_name' => 'login_signup']
return view( 'templates/header', $data, $view_cache )
. view( 'login/signup' )
. view( 'templates/footer' );
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )