Configuration methods

PHPTAL tries to use best defaults possible and you shouldn't need to change any of the settings.

All of these are methods of the PHPTAL class. set* methods return instance of their class, so you can chain them:

<?php
  echo $phptal->setPhpCodeDestination('/tmp/phptal')->setOutputMode(PHPTAL::XML)->setTemplate('tpl.zpt')->execute();
?>

то же самое, что и:

<?php
  $phptal->setPhpCodeDestination('/tmp/phptal');
  $phptal->setOutputMode(PHPTAL::XML);
  $phptal->setTemplate('tpl.zpt');
  echo $phptal->execute();
?>

There are other set* methods for filters, internationalization, etc. They have been described in other sections of this manual.