create
[ class tree: create ] [ index: create ] [ all elements ]

example

  1. <?php
  2.  
  3. /**
  4.  * Creates a Word document with three columns.
  5.  *
  6.  * @category   Phpdocx
  7.  * @package    examples
  8.  * @subpackage easy
  9.  * @copyright  Copyright (c) 2009-2013 Narcea Producciones Multimedia S.L.
  10.  *              (http://www.2mdc.com)
  11.  * @license    http://www.phpdocx.com/wp-content/themes/lightword/pro_license.php
  12.  * @version    2012.12.26
  13.  * @link       http://www.phpdocx.com
  14.  * @since      2012.12.26
  15.  */
  16. require_once '../../classes/CreateDocx.inc';
  17.  
  18. $docx new CreateDocx();
  19.  
  20. $text 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, ' .
  21.     'sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut ' .
  22.     'enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut' .
  23.     'aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit ' .
  24.     'in voluptate velit esse cillum dolore eu fugiat nulla pariatur. ' .
  25.     'Excepteur sint occaecat cupidatat non proident, sunt in culpa qui ' .
  26.     'officia deserunt mollit anim id est laborum.';
  27.  
  28. $docx->addText($text);
  29.  
  30. $paramsPage array(
  31.     'titlePage' => 1,
  32.     'numberCols' => 3,
  33.     'orient' => 'normal',
  34.     'top' => 4000,
  35.     'bottom' => 4000,
  36.     'right' => 4000,
  37.     'left' => 4000
  38. );
  39.  
  40. $docx->createDocx('../docx/example_textColumns'$paramsPage);

Documentation generated on Mon, 13 Jan 2014 13:44:10 +0100 by phpDocumentor 1.4.4