Ver Mensaje Individual
  #1 (permalink)  
Antiguo 22/10/2011, 06:20
jruiz_fdez
 
Fecha de Ingreso: febrero-2005
Ubicación: Madrid
Mensajes: 549
Antigüedad: 19 años, 2 meses
Puntos: 0
Problema con templatepower

Hola,

estoy aprendiendo a utilizar la plantilla Template Power. Para ello, me he descargado un ejemplo sencillo de su web oficial

Éste es el código PHP:
Código:
<?php
 include( "./class.TemplatePower.inc.php");

 //make a new TemplatePower object
  $tpl = new TemplatePower( "./simple.tpl" );

 //let TemplatePower do its thing, parsing etc.
  $tpl->prepare();

 //assign a value to {name}
  $tpl->assign("name", "RoVeL");

 //print the result
  $tpl->printToScreen();
?>
Y éste es el código HTML:
Código:
<html>
<head>
  <title>Simple Template Example</title>
</head>

<body>

  <H2>Welcome {name}!</H2>

</body>
</html>
Sin embargo, al ejecutar el .php me da este error: Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0 Fatal error: Unknown: Failed opening required '/var/www/html/templatepower/simple_example.php' (include_path='.:/php/includes:/usr/share/pear:/usr/share/php') in Unknown on line 0

He editado el php.ini y he incluido en el include_path los directorios .:/php/includes:/usr/share/pear:/usr/share/php. Reinicio Apache, vuelvo a ejecutar el .php pero me sigue apareciendo el mismo error.

¿Alguien puede ayudarme?

Muchas gracias por adelantado,
Jose
__________________
Nadie dijo que ésto iba a ser fácil