Witam mam taki kod
  1. require('./lib/Opl/Base.php');
  2. Opl_Loader::setDirectory('./lib/');
  3. Opl_Loader::register();
  4.  
  5. try
  6. {
  7. $tpl = new Opt_Class();
  8. $tpl->sourceDir = './templates/';
  9. $tpl->compileDir = './templates_c/';
  10. $tpl->setup();
  11.  
  12.  
  13. $layoutView = new Opt_View('przyklad1.tpl');
  14.  
  15. $list = array () ;
  16. $list[] = array ( 'id' => 1 , 'name' => 'Produkt 1' , 'description' => 'Opis produktu 1' );
  17. $list[] = array ( 'id' => 2 , 'name' => 'Produkt 2' , 'description' => 'Opis produktu 2' );
  18.  
  19. $layoutView->products = $list ;
  20.  
  21.  
  22.  
  23. $out = new Opt_Output_Http;
  24. $out->render($layoutView);
  25.  
  26. }
  27. catch(Opt_Exception $exception)
  28. {
  29. Opt_Error_Handler($exception);
  30. }


Szablon
  1. <tr>
  2. <th>#</th>
  3. <th>Nazwa</th>
  4. <th>Opis</th>
  5. </tr>
  6.  
  7. <opt:section name="products">
  8. <tr>
  9. <td>{$products.id}</td>
  10. <td>{$products.name}</td>
  11. <td>{$products.description}</td>
  12. </tr>
  13. </opt:section>
  14. </body>
  15. </html>

I nie wiem czemu ale nie chce mi się wyświetlać strona pojawia się komunikat
nie może wyświetlić witryny sieci Web.
Błąd jest tylko wtedy kiedy próbuje użyć sekcji. Proszę o pomoc