stavo guardando con interesse questo framework per un possibile progetto grandino che dovrei svolgere.
quello che mi chiedevo era se fosse possibile usare un template unico nel quel modificare solo il contenuto.
ho già visto questo link: http://codeigniter.com/user_guide/libraries/parser.html
ma nn è quello che intendo.
quello che intendo è più qualcosa del genere:
insomma è tutto praticamente statico, tranne il contenuto centrale che cambia a seconda della pagina richiesta.Codice PHP:
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title><?php echo $title ?></title>
<link type="text/css" rel="stylesheet" href="template/css/style.css" media="screen" />
<link type="text/css" rel="stylesheet" href="template/css/smoothDivScroll.css" media="screen" />
<link type='text/css' rel='stylesheet' href='http://fonts.googleapis.com/css?family=Salsa' media="screen" />
<link rel="shortcut icon" href="template/images/favicon.png" />
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script type="text/javascript" src="lib/jquery.smart3d.js"></script>
<script type="text/javascript" src="lib/jquery-ui-1.8.16.custom.min.js"></script>
VARIE FUNZION JS
</head>
<body>
<div id="main">
<div class="dock" id="dock">
MENU
</div>
</div>
<?php
require_once $tpl; // CONTENUTO
?>
</div>
<div id="footer">
FOOTER
</p>
</div>
</body>
</html>