• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Template question?


This is my first time to use a template using CodeIgniter.

I found this site below,

And i followed the instruction.
But unfortunately i encountered this error message below,

Is anyone familiar with this template?
Or is there any better than this template system?

Thanks in advanced.

I assume line 12 contains

Did you load the template library?

Or maybe you can suggest a complete tutorial on managing and outputting contents on a master page?
They say using php codes alone is better than using any template system.
I'm a little confused right now.

There is no definitive guide on how to generate pages, it all depends on your (projects) requirements.

If it's a small site, if the developer has full control, if the development team is small, then PHP in views (or templates) is probably Ok.
If it's a large site, if you have separate backend developers and frontend designers, if the project is built by a large team, then separation of code and presentation is usually required.

When it comes to templates (actually, partials, or sections of a page), Colin's library is quite good. Anther one is Phil Sturgeon's Template library. Both provide the option to generate a page from different sections using a single master layout.
I personally find Colin's library a bit more flexible, as it contains solutions for css and js files as well, and has support for template engines other than CI's internal parser class. It does lack proper theme support, which Phil's library does provide.

I have already loaded it,

class Page extends Controller {
   function Page()
   function index()

      $this->template->render($region = NULL, $buffer = FALSE, $parse = FALSE);

But the same error.
Any advice?


I see you load the parser, but I'm missing

[eluser]Juan Velandia[/eluser]
Hello Ana, I´ve working with this template: http://maestric.com/doc/php/codeigniter_template

It´s extremely simple, and I´ve used it in:


I´m not an expert programmer and it´s been vey helpful



Thanks I'll try your suggestion.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.