Closed piercemcgeough closed 10 years ago
On further research it is the Extends Template Resources im looking for: http://www.smarty.net/docs/en/resources.extends.tpl
I got it working, sorry I must have done something silly.
$this->parser->parse('extends:layouts/base_1.tpl|file:folder/list.tpl', $this->view_data);
Glad you got it working Pierce. Let me know if you do come across anything else (no matter how small or silly).
Solve this question, i am willing to put more bounty, just please solve it.
I was looking on the smarty forum and found how to extend from the controller first before loading the view http://www.smarty.net/forums/viewtopic.php?p=71402&sid=a001c28775ec07f85bce6d3c91b90848
if(!empty($_REQUEST['lightbox']) { $smarty->display("extends:general/{$config->template->base1}|detail.tpl"); } else { $smarty->display("extends:general/{$config->template->base2}|detail.tpl"); }
Is it possible to do this with your Ci-Smarty
$this->parser->parse('login/login.tpl', $this->view_data); Im looking to choose which file to extend first then load the login.tpl