Details
-
Bug
-
Resolution: Unresolved
-
High
-
None
-
4.7.0, 5.0
-
None
Description
Export of a an eZ Publish ContentObject containing an ampersand in an attribute of datatype eztext or ezstring fails.
By changing the following lines in the file extension/ezodf/classes/ezoogenerator.php we were able to fix the problem:
- Class eZOOGenerator
function addHeader( $text, $level = 1, $paragraphArray = array() )
--> Line 299 original:
$headerContents['Text'] = $text;
--> Changed to:
$headerContents['Text'] = htmlspecialchars( $text );
function addParagraph()
--> Line 422 original:
$paragraphArray = array( array( 'Type' => 'text', "Content" => isset( $argArray[0] ) ? $argArray[0] : '' ) );
--> Changed to:
$paragraphArray = array( array( 'Type' => 'text', "Content" => isset( $argArray[0] ) ? htmlspecialchars( $argArray[0] ) : '' ) );