Set Up Template System With Code Igniter - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Set Up Template System With Code Igniter (/showthread.php?tid=46319) |
Set Up Template System With Code Igniter - El Forum - 10-27-2011 [eluser]Unknown[/eluser] I'm very new to CF and MVC in general, but I have been writing php for about a year. I was working through a NetTutsPlus tutorial on how to setup a template system and I already hit some road blocks that I have no idea how to solve. I want to use a template because I want to be as efficient as possible. If it helps, here is a link to the tutorial I worked from http://www.youtube.com/watch?v=gvGymDhY49E 1. I don't know how to change the URL structure. Currently the template system forces me to go to index.php/site/blog for example. 2. I don't know how to pass in dynamic data to my header and footer using this system. 3. What does extends do? Example: "class Site extends CI_Controller" Here is my current setup... views/template.php Code: <?php controllers/site.php Code: <?php views/includes/header.php Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> |