Source for file ex7.php

Documentation is available at ex7.php

  1. <?php
  2.  
  3. /**
  4. * example 7
  5. * demonstrates file includes
  6. *
  7. * @package XTemplate_Examples
  8. * @author Barnabas Debreceni [cranx@users.sourceforge.net]
  9. * @copyright Barnabas Debreceni 2000-2001
  10. * @author Jeremy Coates [cocomp@users.sourceforge.net]
  11. * @copyright Jeremy Coates 2002-2007
  12. * @see license.txt LGPL / BSD license
  13. * @link $HeadURL: https://xtpl.svn.sourceforge.net/svnroot/xtpl/trunk/ex7.php $
  14. * @version $Id: ex7.php 16 2007-01-11 03:02:49Z cocomp $
  15. */
  16.  
  17. include_once('./xtemplate.class.php');
  18.  
  19. $xtpl = new XTemplate('ex7.xtpl');
  20.  
  21. $xtpl->assign('FILENAME', 'ex7-inc.xtpl');
  22.  
  23. // Language is set to English
  24. $xtpl->assign_file('LANGUAGE', 'ex7-inc-eng.xtpl');
  25.  
  26. // Uncomment the line below to set language to German
  27. //$xtpl->assign_file('LANGUAGE', 'ex7-inc-de.xtpl');
  28.  
  29.  
  30. $xtpl->rparse('main.inc');
  31.  
  32. $xtpl->parse('main');
  33. $xtpl->out('main');
  34.  
  35. ?>

Documentation generated on Tue, 29 May 2007 19:29:34 +0100 by phpDocumentor 1.3.0RC3