tutoriel2.php 960 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. /**
  3. * Tutoriel file
  4. * Description : Adding a single image to the document
  5. * You need PHP 5.2 at least
  6. * You need Zip Extension or PclZip library
  7. *
  8. * @copyright GPL License 2008 - Julien Pauli - Cyril PIERRE de GEYER - Anaska (http://www.anaska.com)
  9. * @license http://www.gnu.org/copyleft/gpl.html GPL License
  10. * @version 1.3
  11. */
  12. // Make sure you have Zip extension or PclZip library loaded
  13. // First : include the librairy
  14. require_once('../library/odf.php');
  15. $odf = new odf("tutoriel2.odt");
  16. $odf->setVars('titre','Anaska formation');
  17. $message = "Anaska, leader Français de la formation informatique sur les technologies
  18. Open Source, propose un catalogue de plus de 50 formations dont certaines préparent
  19. aux certifications Linux, MySQL, PHP et PostgreSQL.";
  20. $odf->setVars('message', $message);
  21. $odf->setImage('image', './images/anaska.jpg');
  22. // We export the file
  23. $odf->exportAsAttachedFile();
  24. ?>