Exemple #1
0
 /**
  * Create a new Section
  * 
  * @param int $sectionCount
  * @param mixed $settings
  */
 public function __construct($sectionCount, $settings = null)
 {
     $this->_sectionCount = $sectionCount;
     $this->_settings = new PHPWord_Section_Settings();
     if (!is_null($settings) && is_array($settings)) {
         foreach ($settings as $key => $value) {
             if (substr($key, 0, 1) != '_') {
                 $key = '_' . $key;
             }
             $this->_settings->setSettingValue($key, $value);
         }
     }
 }
Exemple #2
0
 /**
  * Create a new Section
  * 
  * @param int $sectionCount
  * @param mixed $settings
  */
 public function __construct($sectionCount, $settings = null)
 {
     require_once __DIR__ . '/Section/Settings.php';
     $this->_sectionCount = $sectionCount;
     $this->_settings = new Document_Word_Writer_Section_Settings();
     if (!is_null($settings) && is_array($settings)) {
         foreach ($settings as $key => $value) {
             if (substr($key, 0, 1) != '_') {
                 $key = '_' . $key;
             }
             $this->_settings->setSettingValue($key, $value);
         }
     }
 }