Fixed bug with footer preserve text
This commit is contained in:
parent
a6671c2f0f
commit
79f65f04e1
|
|
@ -89,8 +89,10 @@ class PHPWord_Section_Footer_PreserveText
|
||||||
$this->_styleParagraph = $styleParagraph;
|
$this->_styleParagraph = $styleParagraph;
|
||||||
}
|
}
|
||||||
|
|
||||||
$pattern = '/({.*?})/';
|
$matches = preg_split('/({.*?})/', $text, null, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY);
|
||||||
$this->_text = preg_split($pattern, $text, null, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY);
|
if (isset($matches[0])) {
|
||||||
|
$this->_text = $matches[0];
|
||||||
|
}
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue