Implemented an override of allowed language per workspace. This is an expert feature...
[Packages/TYPO3.CMS.git] / t3lib / class.t3lib_flexformtools.php
index a9e633b..d1953c6 100644 (file)
@@ -108,13 +108,13 @@ class t3lib_flexformtools {
         * @param       string          Method name of call back function in object for values
         * @return      boolean         If true, error happened (error string returned)
         */
-       function traverseFlexFormXMLData($table,$field,$row,&$callBackObj,$callBackMethod_value)        {
+       function traverseFlexFormXMLData($table, $field, $row, $callBackObj, $callBackMethod_value) {
 
                if (!is_array($GLOBALS['TCA'][$table]) || !is_array($GLOBALS['TCA'][$table]['columns'][$field]))        {
                        return 'TCA table/field was not defined.';
                }
 
-               $this->callBackObj = &$callBackObj;
+               $this->callBackObj = $callBackObj;
 
                        // Get Data Structure:
                $dataStructArray = t3lib_BEfunc::getFlexFormDS($GLOBALS['TCA'][$table]['columns'][$field]['config'],$row,$table);
@@ -360,7 +360,7 @@ class t3lib_flexformtools {
         * @param       object          Object reference to caller
         * @return      void
         */
-       function cleanFlexFormXML_callBackFunction($dsArr, $data, $PA, $path, &$pObj)   {
+       function cleanFlexFormXML_callBackFunction($dsArr, $data, $PA, $path, $pObj) {
                #debug(array($dsArr, $data, $PA),$path);
                        // Just setting value in our own result array, basically replicating the structure:
                $pObj->setArrayValueByPath($path,$this->cleanFlexFormXML,$data);
@@ -455,6 +455,9 @@ class t3lib_flexformtools {
         * @return      string          XML content.
         */
        function flexArray2Xml($array, $addPrologue=FALSE)      {
+               if ($GLOBALS['TYPO3_CONF_VARS']['BE']['flexformForceCDATA']) {
+                       $this->flexArray2Xml_options['useCDATA'] = 1;
+               }
 
                $options = $GLOBALS['TYPO3_CONF_VARS']['BE']['niceFlexFormXMLtags'] ? $this->flexArray2Xml_options : array();
                $spaceInd = ($GLOBALS['TYPO3_CONF_VARS']['BE']['compactFlexFormXML'] ? -1 : 4);
@@ -471,4 +474,4 @@ class t3lib_flexformtools {
 if (defined('TYPO3_MODE') && $TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['t3lib/class.t3lib_flexformtools.php'])    {
        include_once($TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['t3lib/class.t3lib_flexformtools.php']);
 }
-?>
\ No newline at end of file
+?>