Index: typo3/classes/class.backendsearchmenu.php =================================================================== --- typo3/classes/class.backendsearchmenu.php (revision 7304) +++ typo3/classes/class.backendsearchmenu.php (working copy) @@ -79,7 +79,7 @@ $searchMenu[] = ''; $searchMenu[] = ''; - return implode("\n", $searchMenu); + return implode(LF, $searchMenu); } /** Index: typo3/classes/class.modulemenu.php =================================================================== --- typo3/classes/class.modulemenu.php (revision 7304) +++ typo3/classes/class.modulemenu.php (working copy) @@ -158,11 +158,11 @@ $menu .= $this->renderSubModules($moduleData['subitems'], $menuState); } - $menu .= '' . "\n"; + $menu .= '' . LF; } } - return ($wrapInUl ? '' . "\n" : $menu); + return ($wrapInUl ? '' . LF : $menu); } /** @@ -216,10 +216,10 @@ .''; } - $moduleMenu .= '
  • ' . $submoduleLink . '
  • ' . "\n"; + $moduleMenu .= '
  • ' . $submoduleLink . '
  • ' . LF; } - return ''."\n".$moduleMenu.''."\n"; + return ''.LF.$moduleMenu.''.LF; } /** @@ -501,7 +501,7 @@ var modScriptURL = ""; switch(modName) {' - ."\n".implode("\n", $moduleJavascriptCommands)."\n".' + .LF.implode(LF, $moduleJavascriptCommands).LF.' } '; Index: typo3/classes/class.clearcachemenu.php =================================================================== --- typo3/classes/class.clearcachemenu.php (revision 7304) +++ typo3/classes/class.clearcachemenu.php (working copy) @@ -147,7 +147,7 @@ $cacheMenu[] = ''; - return implode("\n", $cacheMenu); + return implode(LF, $cacheMenu); } /** Index: typo3/classes/class.shortcutmenu.php =================================================================== --- typo3/classes/class.shortcutmenu.php (revision 7304) +++ typo3/classes/class.shortcutmenu.php (working copy) @@ -121,7 +121,7 @@ $shortcutMenu[] = $this->renderMenu(); $shortcutMenu[] = ''; - return implode("\n", $shortcutMenu); + return implode(LF, $shortcutMenu); } /** @@ -203,7 +203,7 @@ $shortcutMenu[] = ''; - $compiledShortcutMenu = implode("\n", $shortcutMenu); + $compiledShortcutMenu = implode(LF, $shortcutMenu); return $compiledShortcutMenu; } Index: typo3/classes/class.workspaceselector.php =================================================================== --- typo3/classes/class.workspaceselector.php (revision 7304) +++ typo3/classes/class.workspaceselector.php (working copy) @@ -240,7 +240,7 @@ $workspaceMenu[] = ''; - return implode("\n", $workspaceMenu); + return implode(LF, $workspaceMenu); } /** Index: typo3/alt_topmenu_dummy.php =================================================================== --- typo3/alt_topmenu_dummy.php (revision 7304) +++ typo3/alt_topmenu_dummy.php (working copy) @@ -139,7 +139,7 @@ '; foreach ($contentArray as $key=>$menucontent) { - $this->content .= implode(chr(10), $menucontent); + $this->content .= implode(LF, $menucontent); } $this->content.=' Index: typo3/wizard_forms.php =================================================================== --- typo3/wizard_forms.php (revision 7304) +++ typo3/wizard_forms.php (working copy) @@ -800,7 +800,7 @@ // Default: if ($vv['type']=='select' || $vv['type']=='radio') { - $thisLine[2]=str_replace(chr(10),', ',str_replace(',','',$vv['options'])); + $thisLine[2]=str_replace(LF,', ',str_replace(',','',$vv['options'])); } elseif ($vv['type']=='check') { if ($vv['default']) $thisLine[2]=1; } elseif (strcmp(trim($vv['default']),'')) { @@ -814,7 +814,7 @@ } } // Finally, implode the lines into a string, and return it: - return implode(chr(10),$inLines); + return implode(LF,$inLines); } /** @@ -827,7 +827,7 @@ function cfgString2CfgArray($cfgStr) { // Traverse the number of form elements: - $tLines=explode(chr(10),$cfgStr); + $tLines=explode(LF,$cfgStr); foreach($tLines as $k => $v) { // Initialize: @@ -870,7 +870,7 @@ switch((string)$confData['type']) { case 'select': case 'radio': - $confData['default'] = implode(chr(10),t3lib_div::trimExplode(',',$parts[2])); + $confData['default'] = implode(LF,t3lib_div::trimExplode(',',$parts[2])); break; default: $confData['default'] = trim($parts[2]); Index: typo3/wizard_tsconfig.php =================================================================== --- typo3/wizard_tsconfig.php (revision 7304) +++ typo3/wizard_tsconfig.php (working copy) @@ -549,7 +549,7 @@ foreach($table['rows'] as $row) { // Linking: - $lP=t3lib_div::trimExplode(chr(10),$row['property'],1); + $lP=t3lib_div::trimExplode(LF,$row['property'],1); $lP2=array(); while(list($k,$lStr)=each($lP)) { $lP2[$k] = $this->linkProperty($lStr,$lStr,$objString,$row['datatype']); Index: typo3/alt_doc.php =================================================================== --- typo3/alt_doc.php (revision 7304) +++ typo3/alt_doc.php (working copy) @@ -938,7 +938,7 @@ if (is_array($this->tceforms->extraFormHeaders)) { $extraTemplate = t3lib_parsehtml::getSubpart($this->doc->moduleTemplate, '###DOCHEADER_EXTRAHEADER###'); - $extraTemplate = t3lib_parsehtml::substituteMarker($extraTemplate, '###EXTRAHEADER###', implode(chr(10), $this->tceforms->extraFormHeaders)); + $extraTemplate = t3lib_parsehtml::substituteMarker($extraTemplate, '###EXTRAHEADER###', implode(LF, $this->tceforms->extraFormHeaders)); } return $extraTemplate; } @@ -1031,7 +1031,7 @@ if (count($this->tceforms->commentMessages)) { $tceformMessages = ' '; } Index: typo3/template.php =================================================================== --- typo3/template.php (revision 7304) +++ typo3/template.php (working copy) @@ -731,19 +731,19 @@ if ($this->docType !== 'html_3') { // Put the XML prologue before or after the doctype declaration according to browser if ($browserInfo['browser'] === 'msie' && $browserInfo['version'] < 7) { - $headerStart = $headerStart . chr(10) . $xmlPrologue; + $headerStart = $headerStart . LF . $xmlPrologue; } else { - $headerStart = $xmlPrologue . chr(10) . $headerStart; + $headerStart = $xmlPrologue . LF . $headerStart; } // Add the xml stylesheet according to doctype if ($this->docType !== 'xhtml_frames') { - $headerStart = $headerStart . chr(10) . $xmlStylesheet; + $headerStart = $headerStart . LF . $xmlStylesheet; } } $this->pageRenderer->setXmlPrologAndDocType($headerStart); - $this->pageRenderer->setHeadTag('' . chr(10). ''); + $this->pageRenderer->setHeadTag('' . LF. ''); $this->pageRenderer->setCharSet($this->charset); $this->pageRenderer->addMetaTag($this->generator()); $this->pageRenderer->addMetaTag($this->xUaCompatible()); @@ -1018,7 +1018,7 @@ $this->inDocStylesArray[] = $this->inDocStyles_TBEstyle; // Implode it all: - $inDocStyles = implode(chr(10), $this->inDocStylesArray); + $inDocStyles = implode(LF, $this->inDocStylesArray); if ($this->styleSheetFile) { $this->pageRenderer->addCssFile($this->backPath . $this->styleSheetFile); @@ -1027,7 +1027,7 @@ $this->pageRenderer->addCssFile($this->backPath . $this->styleSheetFile2); } - $this->pageRenderer->addCssInlineBlock('inDocStyles', $inDocStyles . chr(10) . '/*###POSTCSSMARKER###*/'); + $this->pageRenderer->addCssInlineBlock('inDocStyles', $inDocStyles . LF . '/*###POSTCSSMARKER###*/'); if ($this->styleSheetFile_post) { $this->pageRenderer->addCssFile($this->backPath . $this->styleSheetFile_post); } @@ -1084,11 +1084,11 @@ function insertStylesAndJS($content) { // insert accumulated CSS $this->inDocStylesArray[] = $this->inDocStyles; - $styles = "\n".implode("\n", $this->inDocStylesArray); + $styles = LF.implode(LF, $this->inDocStylesArray); $content = str_replace('/*###POSTCSSMARKER###*/',$styles,$content); // insert accumulated JS - $jscode = $this->JScode."\n".$this->wrapScriptTags(implode("\n", $this->JScodeArray)); + $jscode = $this->JScode.LF.$this->wrapScriptTags(implode(LF, $this->JScodeArray)); $content = str_replace('',$jscode,$content); return $content; @@ -1236,14 +1236,14 @@ function wrapScriptTags($string, $linebreak=TRUE) { if(trim($string)) { // '; $GLOBALS['TSFE']->JSCode.=$JScode; @@ -2948,7 +2948,7 @@ $url = $GLOBALS['TSFE']->baseUrlWrap($LD['totalURL']); $target = $LD['target']; } - $codeLines.="\n".$var.$count."=".$menuName.".add(".$parent.",".$prev.",0,".t3lib_div::quoteJSvalue($title, true).",".t3lib_div::quoteJSvalue($url, true).",".t3lib_div::quoteJSvalue($target, true).");"; + $codeLines.=LF.$var.$count."=".$menuName.".add(".$parent.",".$prev.",0,".t3lib_div::quoteJSvalue($title, true).",".t3lib_div::quoteJSvalue($url, true).",".t3lib_div::quoteJSvalue($target, true).");"; // If the active one should be chosen... $active = ($levelConf['showActive'] && $this->isActive($data['uid'], $MP_var)); // If the first item should be shown @@ -2956,9 +2956,9 @@ // do it... if ($active || $first) { if ($count==1) { - $codeLines.="\n".$menuName.".openID = ".$var.$count.";"; + $codeLines.=LF.$menuName.".openID = ".$var.$count.";"; } else { - $codeLines.="\n".$menuName.".entry[".$parent."].openID = ".$var.$count.";"; + $codeLines.=LF.$menuName.".entry[".$parent."].openID = ".$var.$count.";"; } } // Add submenu... @@ -2973,7 +2973,7 @@ $levelConf['firstLabel'] = $this->mconf['firstLabelGeneral']; } if ($levelConf['firstLabel'] && $codeLines) { - $codeLines.= chr(10).$menuName.'.defTopTitle['.$count.'] = '.t3lib_div::quoteJSvalue($levelConf['firstLabel'], true).';'; + $codeLines.= LF.$menuName.'.defTopTitle['.$count.'] = '.t3lib_div::quoteJSvalue($levelConf['firstLabel'], true).';'; } return $codeLines; } Index: typo3/sysext/cms/tslib/class.tslib_content.php =================================================================== --- typo3/sysext/cms/tslib/class.tslib_content.php (revision 7304) +++ typo3/sysext/cms/tslib/class.tslib_content.php (working copy) @@ -908,7 +908,7 @@ if ($conf['captionSplit'] && $conf['captionSplit.']['cObject']) { $legacyCaptionSplit = 1; $capSplit = $this->stdWrap($conf['captionSplit.']['token'], $conf['captionSplit.']['token.']); - if (!$capSplit) {$capSplit=chr(10);} + if (!$capSplit) {$capSplit=LF;} $captionArray = explode($capSplit, $this->cObjGetSingle($conf['captionSplit.']['cObject'], $conf['captionSplit.']['cObject.'], 'captionSplit.cObject')); foreach ($captionArray as $ca_key => $ca_val) { $captionArray[$ca_key] = $this->stdWrap(trim($captionArray[$ca_key]), $conf['captionSplit.']['stdWrap.']); @@ -1730,7 +1730,7 @@ $dataArr = array(); // Getting the original config if (trim($data)) { - $data = str_replace(chr(10),'||',$data); + $data = str_replace(LF,'||',$data); $dataArr = explode('||',$data); } // Adding the new dataArray config form: @@ -1880,7 +1880,7 @@ } else { $wrap = $wrap ? ' wrap="'.$wrap.'"' : ' wrap="virtual"'; } - $default = $this->getFieldDefaultValue($conf['noValueInsert'], $confData['fieldname'], str_replace('\n',chr(10),trim($parts[2]))); + $default = $this->getFieldDefaultValue($conf['noValueInsert'], $confData['fieldname'], str_replace('\n',LF,trim($parts[2]))); $fieldCode=sprintf('', $confData['fieldname'], $elementIdAttribute, $cols, $rows, $wrap, $addParams, t3lib_div::formatForTextarea($default)); break; @@ -2617,7 +2617,7 @@ } // fetching params - $lines = explode(chr(10), $this->stdWrap($conf['params'],$conf['params.'])); + $lines = explode(LF, $this->stdWrap($conf['params'],$conf['params.'])); foreach ($lines as $l) { $parts = explode('=', $l); $parameter = strtolower(trim($parts[0])); @@ -2716,7 +2716,7 @@ //custom parameter entry $rawTS = $val['mmParamCustomEntry']; //read and merge - $tmp = t3lib_div::trimExplode(chr(10), $rawTS); + $tmp = t3lib_div::trimExplode(LF, $rawTS); if (count($tmp)) { foreach ($tmp as $tsLine) { if (substr($tsLine, 0, 1) != '#' && $pos = strpos($tsLine, '.')) { @@ -2783,7 +2783,7 @@ $paramsArray = array_merge((array) $typeConf['default.']['params.'], (array) $conf['params.'], $conf['predefined']); $conf['params']= ''; foreach ($paramsArray as $key => $value) { - $conf['params'] .= $key . '=' . $value . chr(10); + $conf['params'] .= $key . '=' . $value . LF; } $content = $this->MULTIMEDIA($conf); break; @@ -2942,10 +2942,10 @@ if (is_array($conf['params.'])) { t3lib_div::remapArrayKeys($conf['params.'], $typeConf['mapping.']['params.']); foreach ($conf['params.'] as $key => $value) { - $params .= $qtObject . '.addParam("' .$key . '", "' . $value . '");' . chr(10); + $params .= $qtObject . '.addParam("' .$key . '", "' . $value . '");' . LF; } } - $params = ($params ? substr($params, 0, -2) : '') . chr(10) . $qtObject . '.write("' . $replaceElementIdString . '");'; + $params = ($params ? substr($params, 0, -2) : '') . LF . $qtObject . '.write("' . $replaceElementIdString . '");'; $alternativeContent = $this->stdWrap($conf['alternativeContent'], $conf['alternativeContent.']); $layout = $this->stdWrap($conf['layout'], $conf['layout.']); @@ -3791,7 +3791,7 @@ $content=preg_replace("/\r?\n[\t ]*\r?\n/",$conf['doubleBrTag'],$content); } if ($conf['br']) {$content=nl2br($content);} - if ($conf['brTag']) {$content= str_replace(chr(10),$conf['brTag'],$content);} + if ($conf['brTag']) {$content= str_replace(LF,$conf['brTag'],$content);} if ($conf['encapsLines.']) {$content=$this->encaps_lineSplit($content,$conf['encapsLines.']);} if ($conf['keywords']) {$content= $this->keywords($content);} if ($conf['innerWrap'] || $conf['innerWrap.']){$content=$this->wrap($content, $this->stdWrap($conf['innerWrap'], $conf['innerWrap.']));} @@ -4170,13 +4170,13 @@ $parts = explode('|',$str); $output = - chr(10).str_pad('',$parts[0],chr(9)). + LF.str_pad('',$parts[0],TAB). ''. - chr(10).str_pad('',$parts[0]+1,chr(9)). + LF.str_pad('',$parts[0]+1,TAB). $content. - chr(10).str_pad('',$parts[0],chr(9)). + LF.str_pad('',$parts[0],TAB). ''. - chr(10).str_pad('',$parts[0]+1,chr(9)); + LF.str_pad('',$parts[0]+1,TAB); return $output; } @@ -4818,10 +4818,10 @@ $tagName=strtolower($htmlParser->getFirstTagName($v)); $cfg=$conf['externalBlocks.'][$tagName.'.']; if ($cfg['stripNLprev'] || $cfg['stripNL']) { - $parts[$k-1]=preg_replace('/'.chr(13).'?'.chr(10).'[ ]*$/', '', $parts[$k-1]); + $parts[$k-1]=preg_replace('/'.CR.'?'.LF.'[ ]*$/', '', $parts[$k-1]); } if ($cfg['stripNLnext'] || $cfg['stripNL']) { - $parts[$k+1]=preg_replace('/^[ ]*'.chr(13).'?'.chr(10).'/', '', $parts[$k+1]); + $parts[$k+1]=preg_replace('/^[ ]*'.CR.'?'.LF.'/', '', $parts[$k+1]); } } } @@ -4857,7 +4857,7 @@ $colParts[$kkk] = $htmlParser->removeFirstAndLastTag($vvv); if ($cfg['HTMLtableCells.'][$cc.'.']['callRecursive'] || (!isset($cfg['HTMLtableCells.'][$cc.'.']['callRecursive']) && $cfg['HTMLtableCells.']['default.']['callRecursive'])) { - if ($cfg['HTMLtableCells.']['addChr10BetweenParagraphs']) $colParts[$kkk]=str_replace('

    ','

    '.chr(10).'

    ',$colParts[$kkk]); + if ($cfg['HTMLtableCells.']['addChr10BetweenParagraphs']) $colParts[$kkk]=str_replace('

    ','

    '.LF.'

    ',$colParts[$kkk]); $colParts[$kkk] = $this->parseFunc($colParts[$kkk], $conf); } @@ -4941,7 +4941,7 @@ $data = substr($theValue,$pointer,$len); // $data is the content until the next parameters['allParams']=trim($currentTag[1]); if ($stripNL) { // Removes NL in the beginning and end of the tag-content AND at the end of the currentTagBuffer. $stripNL depends on the configuration of the current tag - $contentAccum[$contentAccumP-1] = preg_replace('/'.chr(13).'?'.chr(10).'[ ]*$/', '', $contentAccum[$contentAccumP-1]); - $contentAccum[$contentAccumP] = preg_replace('/^[ ]*'.chr(13).'?'.chr(10).'/', '', $contentAccum[$contentAccumP]); - $contentAccum[$contentAccumP] = preg_replace('/'.chr(13).'?'.chr(10).'[ ]*$/', '', $contentAccum[$contentAccumP]); + $contentAccum[$contentAccumP-1] = preg_replace('/'.CR.'?'.LF.'[ ]*$/', '', $contentAccum[$contentAccumP-1]); + $contentAccum[$contentAccumP] = preg_replace('/^[ ]*'.CR.'?'.LF.'/', '', $contentAccum[$contentAccumP]); + $contentAccum[$contentAccumP] = preg_replace('/'.CR.'?'.LF.'[ ]*$/', '', $contentAccum[$contentAccumP]); } $this->data[$this->currentValKey] = $contentAccum[$contentAccumP]; $newInput=$this->cObjGetSingle($theName,$theConf,'/parseFunc/.tags.'.$tag[0]); // fetch the content object @@ -5097,16 +5097,16 @@ } /** - * Lets you split the content by chr(10) and proces each line independently. Used to format content made with the RTE. + * Lets you split the content by LF and proces each line independently. Used to format content made with the RTE. * * @param string The input value * @param array TypoScript options - * @return string The processed input value being returned; Splitted lines imploded by chr(10) again. + * @return string The processed input value being returned; Splitted lines imploded by LF again. * @access private * @link http://typo3.org/doc.0.html?&tx_extrepmgm_pi1[extUid]=270&tx_extrepmgm_pi1[tocEl]=323&cHash=a19312be78 */ function encaps_lineSplit($theValue, $conf) { - $lParts = explode(chr(10),$theValue); + $lParts = explode(LF,$theValue); $encapTags = t3lib_div::trimExplode(',',strtolower($conf['encapsTagList']),1); $nonWrappedTag = $conf['nonWrappedTag']; @@ -5174,7 +5174,7 @@ $lParts[$k] = $str_content; } - return implode(chr(10),$lParts); + return implode(LF,$lParts); } /** @@ -5194,7 +5194,7 @@ $textstr = $textpieces[0]; $initP = '?id='.$GLOBALS['TSFE']->id.'&type='.$GLOBALS['TSFE']->type; for($i=1; $i<$pieces; $i++) { - $len=strcspn($textpieces[$i],chr(32).chr(9).chr(13).chr(10)); + $len=strcspn($textpieces[$i],chr(32).TAB.CRLF); if (trim(substr($textstr,-1))=='' && $len) { $lastChar=substr($textpieces[$i],$len-1,1); @@ -5264,7 +5264,7 @@ $textstr = $textpieces[0]; $initP = '?id='.$GLOBALS['TSFE']->id.'&type='.$GLOBALS['TSFE']->type; for($i=1; $i<$pieces; $i++) { - $len = strcspn($textpieces[$i],chr(32).chr(9).chr(13).chr(10)); + $len = strcspn($textpieces[$i],chr(32).TAB.CRLF); if (trim(substr($textstr,-1))=='' && $len) { $lastChar = substr($textpieces[$i],$len-1,1); if (!preg_match('/[A-Za-z0-9]/',$lastChar)) {$len--;} @@ -6630,7 +6630,7 @@ */ function processParams($params) { $paramArr=array(); - $lines=t3lib_div::trimExplode(chr(10),$params,1); + $lines=t3lib_div::trimExplode(LF,$params,1); foreach($lines as $val) { $pair = explode('=',$val,2); if (!t3lib_div::inList('#,/',substr(trim($pair[0]),0,1))) { @@ -6647,7 +6647,7 @@ * @return string Cleaned up string, keywords will be separated by a comma only. */ function keywords($content) { - $listArr = preg_split('/[,;' . chr(10) . ']/', $content); + $listArr = preg_split('/[,;' . LF . ']/', $content); foreach ($listArr as $k => $v) { $listArr[$k]=trim($v); } @@ -6771,12 +6771,12 @@ $emailContent = trim($msg); if ($emailContent) { - $parts = explode(chr(10), $emailContent, 2); // First line is subject + $parts = explode(LF, $emailContent, 2); // First line is subject $subject=trim($parts[0]); $plain_message=trim($parts[1]); - if ($recipients) $GLOBALS['TSFE']->plainMailEncoded($recipients, $subject, $plain_message, implode(chr(10),$headers)); - if ($cc) $GLOBALS['TSFE']->plainMailEncoded($cc, $subject, $plain_message, implode(chr(10),$headers)); + if ($recipients) $GLOBALS['TSFE']->plainMailEncoded($recipients, $subject, $plain_message, implode(LF,$headers)); + if ($cc) $GLOBALS['TSFE']->plainMailEncoded($cc, $subject, $plain_message, implode(LF,$headers)); return true; } } @@ -6938,7 +6938,7 @@ * @see gifBuilderTextBox() */ function linebreaks($string,$chars,$maxLines=0) { - $lines = explode(chr(10),$string); + $lines = explode(LF,$string); $lineArr=Array(); $c=0; foreach ($lines as $paragraph) { @@ -7991,16 +7991,16 @@ if (!$conf['src'] && !$typeNum) { $typeNum = -1; } - $content.='frameParams($conf,$typeNum).' />'.chr(10); + $content.='frameParams($conf,$typeNum).' />'.LF; break; case 'FRAMESET': $frameset = t3lib_div::makeInstance('tslib_frameset'); - $content.=$frameset->make($conf).chr(10); + $content.=$frameset->make($conf).LF; break; } } } - return 'framesetParams($setup).'>'.chr(10).$content.''; + return 'framesetParams($setup).'>'.LF.$content.''; } } @@ -8094,7 +8094,7 @@ // If width is defined AND there has been no change to the default table params, then extend them to a tablewidth of 1 if ($valPairs[4] && $this->default_tableParams==$this->tableParams) {$this->tableParams.=' width="1"';} // Init: - $this->begin = chr(10).'tableParams.'>'; + $this->begin = LF.'
    tableParams.'>'; $this->end = '
    '; $rows=array(); $widthImg = ''; @@ -8222,7 +8222,7 @@ if (!$rows && $cols) $rows=1; // If there are no rows in the middle but still som columns... if ($rows&&$cols) { - $res = chr(10).'tableParams.'>'; + $res = LF.'
    tableParams.'>'; // top offset: if ($offArr[1]) { $xoff = $offArr[0] ? 1 : 0; Index: typo3/sysext/openid/sv1/class.tx_openid_sv1.php =================================================================== --- typo3/sysext/openid/sv1/class.tx_openid_sv1.php (revision 7304) +++ typo3/sysext/openid/sv1/class.tx_openid_sv1.php (working copy) @@ -194,7 +194,7 @@ // we must change the password in the record to a long random string so // that this user cannot be authenticated with other service. if (is_array($userRecord)) { - $userRecord[$this->authenticationInformation['db_user']['userident_column']] = uniqid($this->prefixId . chr(10), true); + $userRecord[$this->authenticationInformation['db_user']['userident_column']] = uniqid($this->prefixId . LF, true); } } return $userRecord; Index: typo3/sysext/tstemplate_ceditor/class.tx_tstemplateceditor.php =================================================================== --- typo3/sysext/tstemplate_ceditor/class.tx_tstemplateceditor.php (revision 7304) +++ typo3/sysext/tstemplate_ceditor/class.tx_tstemplateceditor.php (working copy) @@ -119,7 +119,7 @@ if ($tmpl->changed) { // Set the data to be saved $recData=array(); - $recData["sys_template"][$saveId]["constants"] = implode($tmpl->raw,chr(10)); + $recData["sys_template"][$saveId]["constants"] = implode($tmpl->raw,LF); // Create new tce-object $tce = t3lib_div::makeInstance("t3lib_TCEmain"); $tce->stripslashes_values=0; Index: typo3/sysext/statictemplates/media/scripts/freesite_dummy_page_menu.php =================================================================== --- typo3/sysext/statictemplates/media/scripts/freesite_dummy_page_menu.php (revision 7304) +++ typo3/sysext/statictemplates/media/scripts/freesite_dummy_page_menu.php (working copy) @@ -55,7 +55,7 @@ $key = $row['uid']; $val = $row['title']; $content.= ''.$val.'
    '; - $specialComment.= '[globalVar= based_on_uid='.$key.']'.chr(10); + $specialComment.= '[globalVar= based_on_uid='.$key.']'.LF; } // Select subcategories of template folder. $page_res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('*', 'pages', 'pid='.intval($pid).' AND deleted=0 AND hidden=0 AND starttime=0 AND endtime=0 AND fe_group=0', '', 'sorting'); @@ -67,7 +67,7 @@ $key = $row['uid']; $val = $page_row['title'].' / '.$row['title']; $content.= ''.$val.'
    '; - $specialComment.= '[globalVar= based_on_uid='.$key.']'.chr(10); + $specialComment.= '[globalVar= based_on_uid='.$key.']'.LF; } } } Index: typo3/sysext/statictemplates/media/scripts/tmenu_layers.php =================================================================== --- typo3/sysext/statictemplates/media/scripts/tmenu_layers.php (revision 7304) +++ typo3/sysext/statictemplates/media/scripts/tmenu_layers.php (working copy) @@ -375,7 +375,7 @@ GLV_timeout["'.$this->WMid.'"] = GLV_date.getTime(); GLV_timeoutRef["'.$this->WMid.'"] = '.t3lib_div::intInRange($this->mconf['hideMenuTimer'],0,20000).'; GLV_menuXY["'.$this->WMid.'"] = new Array(); -'.implode(chr(10),$this->WMxyArray).' +'.implode(LF,$this->WMxyArray).' '.$this->WMrestoreVars; if ($this->mconf['freezeMouseover']) { @@ -384,14 +384,14 @@ function GL'.$this->WMid.'_over(mitm_id) { GL'.$this->WMid.'_out(""); // removes any old roll over state of an item. Needed for alwaysKeep and Opera browsers. switch(mitm_id) { -'.implode(chr(10),$this->VMmouseoverActions).' +'.implode(LF,$this->VMmouseoverActions).' } GLV_currentROitem["'.$this->WMid.'"]=mitm_id; } function GL'.$this->WMid.'_out(mitm_id) { if (!mitm_id) mitm_id=GLV_currentROitem["'.$this->WMid.'"]; switch(mitm_id) { -'.implode(chr(10),$this->VMmouseoutActions).' +'.implode(LF,$this->VMmouseoutActions).' } } '; @@ -399,7 +399,7 @@ $GLOBALS["TSFE"]->JSCode.= ' function GL'.$this->WMid.'_getMouse(e) { if (GLV_menuOn["'.$this->WMid.'"]!=null && !GLV_dontFollowMouse["'.$this->WMid.'"]){ -'.implode(chr(10),$GLV_menuOn).' +'.implode(LF,$GLV_menuOn).' } GL_mouseMoveEvaluate("'.$this->WMid.'"); } @@ -407,7 +407,7 @@ '.$this->WMhideCode.' } function GL'.$this->WMid.'_doTop(WMid,id) { -'.trim(implode(chr(10),$DoTop)).' +'.trim(implode(LF,$DoTop)).' } function GL'.$this->WMid.'_restoreMenu() { '.$this->WMrestoreScript.' @@ -428,7 +428,7 @@ $GLOBALS['TSFE']->JSeventFuncCalls['onmousemove'][$this->WMid]= 'GL'.$this->WMid.'_getMouse(e);'; $GLOBALS['TSFE']->JSeventFuncCalls['onmouseup'][$this->WMid]= 'GL_mouseUp(\''.$this->WMid.'\',e);'; - $GLOBALS['TSFE']->divSection.=implode($this->divLayers,chr(10)).chr(10); + $GLOBALS['TSFE']->divSection.=implode($this->divLayers,LF).LF; return parent::extProc_finish(); } Index: typo3/sysext/statictemplates/media/scripts/gmenu_layers.php =================================================================== --- typo3/sysext/statictemplates/media/scripts/gmenu_layers.php (revision 7304) +++ typo3/sysext/statictemplates/media/scripts/gmenu_layers.php (working copy) @@ -375,7 +375,7 @@ GLV_timeout["'.$this->WMid.'"] = GLV_date.getTime(); GLV_timeoutRef["'.$this->WMid.'"] = '.t3lib_div::intInRange($this->mconf['hideMenuTimer'],0,20000).'; GLV_menuXY["'.$this->WMid.'"] = new Array(); -'.implode(chr(10),$this->WMxyArray).' +'.implode(LF,$this->WMxyArray).' '.$this->WMrestoreVars; if ($this->mconf['freezeMouseover']) { @@ -384,14 +384,14 @@ function GL'.$this->WMid.'_over(mitm_id) { GL'.$this->WMid.'_out(""); // removes any old roll over state of an item. Needed for alwaysKeep and Opera browsers. switch(mitm_id) { -'.implode(chr(10),$this->VMmouseoverActions).' +'.implode(LF,$this->VMmouseoverActions).' } GLV_currentROitem["'.$this->WMid.'"]=mitm_id; } function GL'.$this->WMid.'_out(mitm_id) { if (!mitm_id) mitm_id=GLV_currentROitem["'.$this->WMid.'"]; switch(mitm_id) { -'.implode(chr(10),$this->VMmouseoutActions).' +'.implode(LF,$this->VMmouseoutActions).' } } '; @@ -399,7 +399,7 @@ $GLOBALS["TSFE"]->JSCode.= ' function GL'.$this->WMid.'_getMouse(e) { if (GLV_menuOn["'.$this->WMid.'"]!=null && !GLV_dontFollowMouse["'.$this->WMid.'"]){ -'.implode(chr(10),$GLV_menuOn).' +'.implode(LF,$GLV_menuOn).' } GL_mouseMoveEvaluate("'.$this->WMid.'"); } @@ -407,7 +407,7 @@ '.$this->WMhideCode.' } function GL'.$this->WMid.'_doTop(WMid,id) { -'.trim(implode(chr(10),$DoTop)).' +'.trim(implode(LF,$DoTop)).' } function GL'.$this->WMid.'_restoreMenu() { '.$this->WMrestoreScript.' @@ -428,7 +428,7 @@ $GLOBALS['TSFE']->JSeventFuncCalls['onmousemove'][$this->WMid]= 'GL'.$this->WMid.'_getMouse(e);'; $GLOBALS['TSFE']->JSeventFuncCalls['onmouseup'][$this->WMid]= 'GL_mouseUp(\''.$this->WMid.'\',e);'; - $GLOBALS['TSFE']->divSection.=implode($this->divLayers,chr(10)).chr(10); + $GLOBALS['TSFE']->divSection.=implode($this->divLayers,LF).LF; return parent::extProc_finish(); } Index: typo3/sysext/tstemplate_info/class.tx_tstemplateinfo.php =================================================================== --- typo3/sysext/tstemplate_info/class.tx_tstemplateinfo.php (revision 7304) +++ typo3/sysext/tstemplate_info/class.tx_tstemplateinfo.php (working copy) @@ -484,12 +484,12 @@ ); $outCode.= $this->tableRow( $GLOBALS['LANG']->getLL('constants'), - sprintf($GLOBALS['LANG']->getLL('editToView'), (trim($tplRow[constants]) ? count(explode(chr(10), $tplRow[constants])) : 0)), + sprintf($GLOBALS['LANG']->getLL('editToView'), (trim($tplRow[constants]) ? count(explode(LF, $tplRow[constants])) : 0)), 'constants' ); $outCode.= $this->tableRow( $GLOBALS['LANG']->getLL('setup'), - sprintf($GLOBALS['LANG']->getLL('editToView'), (trim($tplRow[config]) ? count(explode(chr(10), $tplRow[config])) : 0)), + sprintf($GLOBALS['LANG']->getLL('editToView'), (trim($tplRow[config]) ? count(explode(LF, $tplRow[config])) : 0)), 'config' ); $outCode = '
    '.$outCode.'
    '; Index: typo3/sysext/tstemplate_objbrowser/class.tx_tstemplateobjbrowser.php =================================================================== --- typo3/sysext/tstemplate_objbrowser/class.tx_tstemplateobjbrowser.php (revision 7304) +++ typo3/sysext/tstemplate_objbrowser/class.tx_tstemplateobjbrowser.php (working copy) @@ -261,7 +261,7 @@ ); t3lib_FlashMessageQueue::addMessage($propertyAddedMessage); - $line.=chr(10).$pline; + $line.=LF.$pline; } } elseif ($POST['update_value']) { $pline = $name . " = " . trim($POST['data'][$name]['value']); @@ -273,7 +273,7 @@ ); t3lib_FlashMessageQueue::addMessage($updatedMessage); - $line .= chr(10) . $pline; + $line .= LF . $pline; } elseif ($POST['clear_object']) { if ($POST['data'][$name]['clearValue']) { $pline = $name . ' >'; @@ -285,7 +285,7 @@ ); t3lib_FlashMessageQueue::addMessage($objectClearedMessage); - $line .= chr(10) . $pline; + $line .= LF . $pline; } } } Index: typo3/sysext/rtehtmlarea/pi1/class.tx_rtehtmlarea_pi1.php =================================================================== --- typo3/sysext/rtehtmlarea/pi1/class.tx_rtehtmlarea_pi1.php (revision 7304) +++ typo3/sysext/rtehtmlarea/pi1/class.tx_rtehtmlarea_pi1.php (working copy) @@ -85,7 +85,7 @@ // Setting the list of dictionaries if (!$safe_mode_is_enabled && (!$this->pspell_is_available || $this->forceCommandMode)) { $dictionaryList = shell_exec( $this->AspellDirectory.' dump dicts'); - $dictionaryList = implode(',', t3lib_div::trimExplode(chr(10), $dictionaryList, 1)); + $dictionaryList = implode(',', t3lib_div::trimExplode(LF, $dictionaryList, 1)); } if (empty($dictionaryList)) { $dictionaryList = t3lib_div::_POST('showDictionaries'); @@ -177,12 +177,12 @@ $tmpFileName = t3lib_div::tempnam($this->filePrefix); if($filehandle = fopen($tmpFileName,'wb')) { foreach ($to_p_dict as $personal_word) { - $cmd = '&' . $personal_word . "\n"; + $cmd = '&' . $personal_word . LF; echo $cmd; fwrite($filehandle, $cmd, strlen($cmd)); } foreach ($to_r_list as $replace_pair) { - $cmd = '$$ra ' . $replace_pair[0] . ' , ' . $replace_pair[1] . "\n"; + $cmd = '$$ra ' . $replace_pair[0] . ' , ' . $replace_pair[1] . LF; echo $cmd; fwrite($filehandle, $cmd, strlen($cmd)); } @@ -192,7 +192,7 @@ fclose($filehandle); // $this->personalDictsArg has already been escapeshellarg()'ed above, it is an optional paramter and might be empty here $AspellCommand = 'cat ' . escapeshellarg($tmpFileName) . ' | ' . $this->AspellDirectory . ' -a --mode=none' . $this->personalDictsArg . ' --lang=' . escapeshellarg($this->dictionary) . ' --encoding=' . escapeshellarg($this->aspellEncoding) . ' 2>&1'; - print $AspellCommand . "\n"; + print $AspellCommand . LF; print shell_exec($AspellCommand); t3lib_div::unlink_tempfile($tmpFileName); echo('Personal word list was updated.'); @@ -254,7 +254,7 @@ '; $this->result .= ''; - $this->result .= preg_replace('/'.preg_quote('').'['.preg_quote(chr(10).chr(13).chr(32)).']*/'.(($this->parserCharset == 'utf-8')?'u':''), '', $this->text); + $this->result .= preg_replace('/'.preg_quote('').'['.preg_quote(LF.CR.chr(32)).']*/'.(($this->parserCharset == 'utf-8')?'u':''), '', $this->text); $this->result .= '

    '.$dictionaries.'
    '; // Closing @@ -366,7 +366,7 @@ $AspellCommand = 'cat ' . escapeshellarg($tmpFileName) . ' | ' . $this->AspellDirectory . ' -a check --mode=none --sug-mode=' . escapeshellarg($this->pspellMode) . $this->personalDictsArg . ' --lang=' . escapeshellarg($this->dictionary) . ' --encoding=' . escapeshellarg($this->aspellEncoding) . ' 2>&1'; $AspellAnswer = shell_exec($AspellCommand); $AspellResultLines = array(); - $AspellResultLines = t3lib_div::trimExplode(chr(10), $AspellAnswer, 1); + $AspellResultLines = t3lib_div::trimExplode(LF, $AspellAnswer, 1); if(substr($AspellResultLines[0],0,6) == 'Error:') echo("{$AspellAnswer}"); t3lib_div::unlink_tempfile($tmpFileName); if(substr($AspellResultLines['1'],0,1) != '*') { Index: typo3/sysext/rtehtmlarea/class.tx_rtehtmlarea_base.php =================================================================== --- typo3/sysext/rtehtmlarea/class.tx_rtehtmlarea_base.php (revision 7304) +++ typo3/sysext/rtehtmlarea/class.tx_rtehtmlarea_base.php (working copy) @@ -931,25 +931,25 @@ $addElementCode = ''; foreach ($mainElements as $elListName => $elValue) { - $addElementCode .= strToLower($elListName) . ' {' . $elValue . '}' . chr(10); + $addElementCode .= strToLower($elListName) . ' {' . $elValue . '}' . LF; } - $stylesheet = $this->thisConfig['mainStyleOverride'] ? $this->thisConfig['mainStyleOverride'] : chr(10) . + $stylesheet = $this->thisConfig['mainStyleOverride'] ? $this->thisConfig['mainStyleOverride'] : LF . 'body.htmlarea-content-body { font-family: ' . $mainStyle_font . '; font-size: '.($this->thisConfig['mainStyle_size'] ? $this->thisConfig['mainStyle_size'] : '12px') . '; color: '.($this->thisConfig['mainStyle_color']?$this->thisConfig['mainStyle_color'] : 'black') . '; background-color: '.($this->thisConfig['mainStyle_bgcolor'] ? $this->thisConfig['mainStyle_bgcolor'] : 'white') . - ';'.$this->thisConfig['mainStyleOverride_add.']['BODY'].'}' . chr(10) . - 'td { ' . $this->thisConfig['mainStyleOverride_add.']['TD'].'}' . chr(10) . - 'div { ' . $this->thisConfig['mainStyleOverride_add.']['DIV'].'}' . chr(10) . - 'pre { ' . $this->thisConfig['mainStyleOverride_add.']['PRE'].'}' . chr(10) . - 'ol { ' . $this->thisConfig['mainStyleOverride_add.']['OL'].'}' . chr(10) . - 'ul { ' . $this->thisConfig['mainStyleOverride_add.']['UL'].'}' . chr(10) . - 'blockquote { ' . $this->thisConfig['mainStyleOverride_add.']['BLOCKQUOTE'].'}' . chr(10) . + ';'.$this->thisConfig['mainStyleOverride_add.']['BODY'].'}' . LF . + 'td { ' . $this->thisConfig['mainStyleOverride_add.']['TD'].'}' . LF . + 'div { ' . $this->thisConfig['mainStyleOverride_add.']['DIV'].'}' . LF . + 'pre { ' . $this->thisConfig['mainStyleOverride_add.']['PRE'].'}' . LF . + 'ol { ' . $this->thisConfig['mainStyleOverride_add.']['OL'].'}' . LF . + 'ul { ' . $this->thisConfig['mainStyleOverride_add.']['UL'].'}' . LF . + 'blockquote { ' . $this->thisConfig['mainStyleOverride_add.']['BLOCKQUOTE'].'}' . LF . $addElementCode; if (is_array($this->thisConfig['inlineStyle.'])) { - $stylesheet .= chr(10) . implode(chr(10), $this->thisConfig['inlineStyle.']) . chr(10); + $stylesheet .= LF . implode(LF, $this->thisConfig['inlineStyle.']) . LF; } } else { $stylesheet = '/* mainStyleOverride and inlineStyle properties ignored. */'; @@ -1023,7 +1023,7 @@ } } foreach ($classesArray as $key => $subArray) { - $JSClassesArray .= 'HTMLArea.classes' . ucfirst($key) . ' = ' . $this->buildNestedJSArray($subArray) . ';' . chr(10); + $JSClassesArray .= 'HTMLArea.classes' . ucfirst($key) . ' = ' . $this->buildNestedJSArray($subArray) . ';' . LF; } return $JSClassesArray; } @@ -1054,7 +1054,7 @@ * @return string Javascript localization array */ function buildJSMainLangArray() { - $JSLanguageArray = 'var HTMLArea_langArray = new Object();' . chr(10); + $JSLanguageArray = 'var HTMLArea_langArray = new Object();' . LF; $labelsArray = array('tooltips' => array(), 'msg' => array(), 'dialogs' => array()); foreach ($labelsArray as $labels => $subArray) { $LOCAL_LANG = t3lib_div::readLLfile('EXT:' . $this->ID . '/htmlarea/locallang_' . $labels . '.xml', $this->language, 'utf-8'); @@ -1065,7 +1065,7 @@ } $labelsArray[$labels] = $LOCAL_LANG[$this->language]; } - $JSLanguageArray .= 'HTMLArea_langArray = ' . json_encode($labelsArray) . ';' . chr(10); + $JSLanguageArray .= 'HTMLArea_langArray = ' . json_encode($labelsArray) . ';' . LF; return $JSLanguageArray; } @@ -1145,9 +1145,9 @@ * @return string filename */ function buildJSMainLangFile($RTEcounter) { - $contents = $this->buildJSMainLangArray() . chr(10); + $contents = $this->buildJSMainLangArray() . LF; foreach ($this->pluginEnabledCumulativeArray[$RTEcounter] as $pluginId) { - $contents .= $this->buildJSLangArray($pluginId) . chr(10); + $contents .= $this->buildJSLangArray($pluginId) . LF; } return $this->writeTemporaryFile('', $this->language.'_'.$this->OutputCharset, 'js', $contents, TRUE); } @@ -1164,7 +1164,7 @@ $LOCAL_LANG = FALSE; $extensionKey = is_object($this->registeredPlugins[$plugin]) ? $this->registeredPlugins[$plugin]->getExtensionKey() : $this->ID; $LOCAL_LANG = t3lib_div::readLLfile('EXT:' . $extensionKey . '/htmlarea/plugins/' . $plugin . '/locallang.xml', $this->language, 'utf-8', 1); - $linebreak = $GLOBALS['TYPO3_CONF_VARS']['EXTCONF'][$this->ID]['enableCompressedScripts'] ? '' : chr(10); + $linebreak = $GLOBALS['TYPO3_CONF_VARS']['EXTCONF'][$this->ID]['enableCompressedScripts'] ? '' : LF; $JSLanguageArray = 'var ' . $plugin . '_langArray = new Object();' . $linebreak; if (is_array($LOCAL_LANG)) { if (!empty($LOCAL_LANG[$this->language])) { @@ -1172,7 +1172,7 @@ } else { $LOCAL_LANG[$this->language] = $LOCAL_LANG['default']; } - $JSLanguageArray .= $plugin . '_langArray = ' . json_encode($LOCAL_LANG[$this->language]) . ';'. chr(10); + $JSLanguageArray .= $plugin . '_langArray = ' . json_encode($LOCAL_LANG[$this->language]) . ';'. LF; } return $JSLanguageArray; } Index: typo3/sysext/rtehtmlarea/extensions/TYPO3Link/class.tx_rtehtmlarea_typo3link.php =================================================================== --- typo3/sysext/rtehtmlarea/extensions/TYPO3Link/class.tx_rtehtmlarea_typo3link.php (revision 7304) +++ typo3/sysext/rtehtmlarea/extensions/TYPO3Link/class.tx_rtehtmlarea_typo3link.php (working copy) @@ -101,7 +101,7 @@ public function buildJSClassesAnchorArray() { global $LANG, $TYPO3_CONF_VARS; - $linebreak = $TYPO3_CONF_VARS['EXTCONF'][$this->htmlAreaRTE->ID]['enableCompressedScripts'] ? '' : chr(10); + $linebreak = $TYPO3_CONF_VARS['EXTCONF'][$this->htmlAreaRTE->ID]['enableCompressedScripts'] ? '' : LF; $JSClassesAnchorArray .= 'HTMLArea.classesAnchorSetup = [ ' . $linebreak; $classesAnchorIndex = 0; foreach ($this->htmlAreaRTE->RTEsetup['properties']['classesAnchor.'] as $label => $conf) { Index: typo3/sysext/felogin/pi1/class.tx_felogin_pi1.php =================================================================== --- typo3/sysext/felogin/pi1/class.tx_felogin_pi1.php (revision 7304) +++ typo3/sysext/felogin/pi1/class.tx_felogin_pi1.php (working copy) @@ -481,7 +481,7 @@ $onSubmit = implode('; ', $onSubmitAr).'; return true;'; } if (count($extraHiddenAr)) { - $extraHidden = implode(chr(10), $extraHiddenAr); + $extraHidden = implode(LF, $extraHiddenAr); } if (!$gpRedirectUrl && $this->redirectUrl) { Index: typo3/sysext/lowlevel/clmods/class.missing_relations.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.missing_relations.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.missing_relations.php (working copy) @@ -104,7 +104,7 @@ // Initialize result array: $listExplain = ' Shows the missing record as header and underneath a list of record fields in which the references are found. '.$this->label_infoString; $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'offlineVersionRecords_m' => array('Offline version records (managed)','These records are offline versions having a pid=-1 and references should never occur directly to their uids.'.$listExplain,3), 'deletedRecords_m' => array('Deleted-flagged records (managed)','These records are deleted with a flag but references are still pointing at them. Keeping the references is useful if you undelete the referenced records later, otherwise the references are lost completely when the deleted records are flushed at some point. Notice that if those records listed are themselves deleted (marked with "DELETED") it is not a problem.'.$listExplain,2), @@ -184,7 +184,7 @@ $trav = array('offlineVersionRecords_m', 'nonExistingRecords_m'); foreach($trav as $tk) { - echo 'Processing managed "'.$tk.'"...'.chr(10); + echo 'Processing managed "'.$tk.'"...'.LF; foreach($resultArray[$tk] as $key => $value) { foreach($value as $hash => $recReference) { echo ' Removing reference to '.$key.' in record "'.$recReference.'": '; @@ -194,10 +194,10 @@ $sysRefObj = t3lib_div::makeInstance('t3lib_refindex'); $error = $sysRefObj->setReferenceValue($hash,NULL); if ($error) { - echo ' t3lib_refindex::setReferenceValue(): '.$error.chr(10); + echo ' t3lib_refindex::setReferenceValue(): '.$error.LF; } else echo 'DONE'; } - echo chr(10); + echo LF; } } } Index: typo3/sysext/lowlevel/clmods/class.missing_files.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.missing_files.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.missing_files.php (working copy) @@ -101,7 +101,7 @@ // Initialize result array: $listExplain = ' Shows the relative filename of missing file as header and under a list of record fields in which the references are found. '.$this->label_infoString; $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'managedFilesMissing' => array('List of missing files managed by TCEmain', $listExplain, 3), 'softrefFilesMissing' => array('List of missing files registered as a soft reference', $listExplain, 2), @@ -157,7 +157,7 @@ */ function main_autoFix($resultArray) { foreach($resultArray['managedFilesMissing'] as $key => $value) { - echo 'Processing file: '.$key.chr(10); + echo 'Processing file: '.$key.LF; $c=0; foreach($value as $hash => $recReference) { echo ' Removing reference in record "'.$recReference.'": '; @@ -167,12 +167,12 @@ $sysRefObj = t3lib_div::makeInstance('t3lib_refindex'); $error = $sysRefObj->setReferenceValue($hash,NULL); if ($error) { - echo ' t3lib_refindex::setReferenceValue(): '.$error.chr(10); - echo 'missing_files: exit on error'.chr(10); + echo ' t3lib_refindex::setReferenceValue(): '.$error.LF; + echo 'missing_files: exit on error'.LF; exit; } else echo "DONE"; } - echo chr(10); + echo LF; } } } Index: typo3/sysext/lowlevel/clmods/class.lost_files.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.lost_files.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.lost_files.php (working copy) @@ -107,7 +107,7 @@ // Initialize result array: $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'managedFiles' => array('Files related to TYPO3 records and managed by TCEmain','These files you definitely want to keep.',0), 'ignoredFiles' => array('Ignored files (index.html, .htaccess etc.)','These files are allowed in uploads/ folder',0), @@ -213,7 +213,7 @@ echo ' ERROR: File "'.$absFileName.'" was not found!'; } } - echo chr(10); + echo LF; } } } Index: typo3/sysext/lowlevel/clmods/class.deleted.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.deleted.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.deleted.php (working copy) @@ -90,7 +90,7 @@ // Initialize result array: $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'deleted' => array('Index of deleted records','These are records from the page tree having the deleted-flag set. The --AUTOFIX option will flush them completely!',1), ), @@ -131,7 +131,7 @@ // Traversing records: foreach($resultArray['deleted'] as $table => $list) { - echo 'Flushing deleted records from table "'.$table.'":'.chr(10); + echo 'Flushing deleted records from table "'.$table.'":'.LF; foreach($list as $uid) { echo ' Flushing record "'.$table.':'.$uid.'": '; if ($bypass = $this->cli_noExecutionCheck($table.':'.$uid)) { @@ -146,10 +146,10 @@ // Return errors if any: if (count($tce->errorLog)) { - echo ' ERROR from "TCEmain":'.chr(10).'TCEmain:'.implode(chr(10).'TCEmain:',$tce->errorLog); + echo ' ERROR from "TCEmain":'.LF.'TCEmain:'.implode(LF.'TCEmain:',$tce->errorLog); } else echo "DONE"; } - echo chr(10); + echo LF; } } } Index: typo3/sysext/lowlevel/clmods/class.orphan_records.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.orphan_records.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.orphan_records.php (working copy) @@ -98,7 +98,7 @@ // Initialize result array: $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'orphans' => array('Index of orphaned records','',3), 'misplaced_at_rootlevel' => array('Records that should not be at root level but are.','Fix manually by moving record into page tree',2), @@ -162,7 +162,7 @@ // Traversing records: foreach($resultArray['orphans'] as $table => $list) { - echo 'Removing orphans from table "'.$table.'":'.chr(10); + echo 'Removing orphans from table "'.$table.'":'.LF; foreach($list as $uid) { echo ' Flushing orphan record "'.$table.':'.$uid.'": '; if ($bypass = $this->cli_noExecutionCheck($table.':'.$uid)) { @@ -177,10 +177,10 @@ // Return errors if any: if (count($tce->errorLog)) { - echo ' ERROR from "TCEmain":'.chr(10).'TCEmain:'.implode(chr(10).'TCEmain:',$tce->errorLog); + echo ' ERROR from "TCEmain":'.LF.'TCEmain:'.implode(LF.'TCEmain:',$tce->errorLog); } else echo 'DONE'; } - echo chr(10); + echo LF; } } } Index: typo3/sysext/lowlevel/clmods/class.double_files.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.double_files.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.double_files.php (working copy) @@ -97,7 +97,7 @@ // Initialize result array: $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'multipleReferencesList_count' => array('Number of multi-reference files','(See below)',0), 'singleReferencesList_count' => array('Number of files correctly referenced','The amount of correct 1-1 references',0), @@ -185,11 +185,11 @@ foreach($resultArray['multipleReferencesList'] as $key => $value) { $absFileName = t3lib_div::getFileAbsFileName($key); if ($absFileName && @is_file($absFileName)) { - echo 'Processing file: '.$key.chr(10); + echo 'Processing file: '.$key.LF; $c=0; foreach($value as $hash => $recReference) { if ($c==0) { - echo ' Keeping '.$key.' for record "'.$recReference.'"'.chr(10); + echo ' Keeping '.$key.' for record "'.$recReference.'"'.LF; } else { // Create unique name for file: $fileFunc = t3lib_div::makeInstance('t3lib_basicFileFunctions'); @@ -206,14 +206,14 @@ $sysRefObj = t3lib_div::makeInstance('t3lib_refindex'); $error = $sysRefObj->setReferenceValue($hash,basename($newName)); if ($error) { - echo ' ERROR: t3lib_refindex::setReferenceValue(): '.$error.chr(10); + echo ' ERROR: t3lib_refindex::setReferenceValue(): '.$error.LF; exit; } else echo "DONE"; } else { echo ' ERROR: File "'.$newName.'" was not created!'; } } - echo chr(10); + echo LF; } $c++; } Index: typo3/sysext/lowlevel/clmods/class.syslog.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.syslog.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.syslog.php (working copy) @@ -82,7 +82,7 @@ // Initialize result array: $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'listing' => array('','',1), 'allDetails' => array('','',0), Index: typo3/sysext/lowlevel/clmods/class.versions.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.versions.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.versions.php (working copy) @@ -95,7 +95,7 @@ // Initialize result array: $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'versions' => array('All versions','Showing all versions of records found',0), 'versions_published' => array('All published versions','This is all records that has been published and can therefore be removed permanently',1), @@ -214,7 +214,7 @@ // Traversing records: foreach($resultArray[$kk] as $table => $list) { - echo 'Flushing published records from table "'.$table.'":'.chr(10); + echo 'Flushing published records from table "'.$table.'":'.LF; foreach($list as $uid) { echo ' Flushing record "'.$table.':'.$uid.'": '; @@ -230,16 +230,16 @@ // Return errors if any: if (count($tce->errorLog)) { - echo ' ERROR from "TCEmain":'.chr(10).'TCEmain:'.implode(chr(10).'TCEmain:',$tce->errorLog); + echo ' ERROR from "TCEmain":'.LF.'TCEmain:'.implode(LF.'TCEmain:',$tce->errorLog); } else echo 'DONE'; } - echo chr(10); + echo LF; } } // Traverse workspace: foreach($resultArray['versions_lost_workspace'] as $table => $list) { - echo 'Resetting workspace to zero for records from table "'.$table.'":'.chr(10); + echo 'Resetting workspace to zero for records from table "'.$table.'":'.LF; foreach($list as $uid) { echo ' Flushing record "'.$table.':'.$uid.'": '; if ($bypass = $this->cli_noExecutionCheck($table.':'.$uid)) { @@ -251,7 +251,7 @@ $GLOBALS['TYPO3_DB']->exec_UPDATEquery($table,'uid='.intval($uid),$fields_values); echo 'DONE'; } - echo chr(10); + echo LF; } } @@ -271,10 +271,10 @@ // Return errors if any: if (count($tce->errorLog)) { - echo ' ERROR from "TCEmain":'.chr(10).'TCEmain:'.implode(chr(10).'TCEmain:',$tce->errorLog); + echo ' ERROR from "TCEmain":'.LF.'TCEmain:'.implode(LF.'TCEmain:',$tce->errorLog); } else echo 'DONE'; } - echo chr(10); + echo LF; } } } Index: typo3/sysext/lowlevel/clmods/class.cleanflexform.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.cleanflexform.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.cleanflexform.php (working copy) @@ -91,7 +91,7 @@ // Initialize result array: $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'dirty' => array('','',2), ), @@ -125,7 +125,7 @@ t3lib_div::loadTCA($tableName); foreach($GLOBALS['TCA'][$tableName]['columns'] as $colName => $config) { if ($config['config']['type']=='flex') { - if ($echoLevel>2) echo chr(10).' [cleanflexform:] Field "'.$colName.'" in '.$tableName.':'.$uid.' was a flexform and...'; + if ($echoLevel>2) echo LF.' [cleanflexform:] Field "'.$colName.'" in '.$tableName.':'.$uid.' was a flexform and...'; $recRow = t3lib_BEfunc::getRecordRaw($tableName,'uid='.intval($uid)); $flexObj = t3lib_div::makeInstance('t3lib_flexformtools'); @@ -180,10 +180,10 @@ // Return errors if any: if (count($tce->errorLog)) { - echo ' ERROR from "TCEmain":'.chr(10).'TCEmain:'.implode(chr(10).'TCEmain:',$tce->errorLog); + echo ' ERROR from "TCEmain":'.LF.'TCEmain:'.implode(LF.'TCEmain:',$tce->errorLog); } else echo 'DONE'; } - echo chr(10); + echo LF; } } } Index: typo3/sysext/lowlevel/clmods/class.rte_images.php =================================================================== --- typo3/sysext/lowlevel/clmods/class.rte_images.php (revision 7304) +++ typo3/sysext/lowlevel/clmods/class.rte_images.php (working copy) @@ -98,7 +98,7 @@ // Initialize result array: $resultArray = array( - 'message' => $this->cli_help['name'].chr(10).chr(10).$this->cli_help['description'], + 'message' => $this->cli_help['name'].LF.LF.$this->cli_help['description'], 'headers' => array( 'completeFileList' => array('Complete list of used RTEmagic files','Both parent and copy are listed here including usage count (which should in theory all be "1"). This list does not exclude files that might be missing.',1), 'RTEmagicFilePairs' => array('Statistical info about RTEmagic files','(copy used as index)',0), @@ -197,7 +197,7 @@ if (is_array($resultArray['doubleFiles'])) { if (!$limitTo || $limitTo==='doubleFiles') { - echo 'FIXING double-usages of RTE files in uploads/: '.chr(10); + echo 'FIXING double-usages of RTE files in uploads/: '.LF; foreach($resultArray['RTEmagicFilePairs'] as $fileName => $fileInfo) { // Only fix something if there is a usage count of more than 1 plus if both original and copy exists: @@ -207,7 +207,7 @@ $c=0; foreach($fileInfo['usedIn'] as $hash => $recordID) { if ($c==0) { - echo ' Keeping file '.$fileName.' for record '.$recordID.chr(10); + echo ' Keeping file '.$fileName.' for record '.$recordID.LF; } else { // CODE below is adapted from "class.tx_impexp.php" where there is support for duplication of RTE images: echo ' Copying file '.basename($fileName).' for record '.$recordID.' '; @@ -243,7 +243,7 @@ $sysRefObj = t3lib_div::makeInstance('t3lib_refindex'); $error = $sysRefObj->setReferenceValue($hash,substr($copyDestName,strlen(PATH_site))); if ($error) { - echo ' - ERROR: t3lib_refindex::setReferenceValue(): '.$error.chr(10); + echo ' - ERROR: t3lib_refindex::setReferenceValue(): '.$error.LF; exit; } else echo " - DONE"; } else { @@ -252,19 +252,19 @@ } } else echo ' - ERROR: Could not construct new unique names for file!'; } else echo ' - ERROR: Maybe directory of file was not within "uploads/"?'; - echo chr(10); + echo LF; } $c++; } } } - } else echo 'Bypassing fixing of double-usages since --AUTOFIX was not "doubleFiles"'.chr(10); + } else echo 'Bypassing fixing of double-usages since --AUTOFIX was not "doubleFiles"'.LF; } if (is_array($resultArray['lostFiles'])) { if ($limitTo==='lostFiles') { - echo 'Removing lost RTEmagic files from folders inside uploads/: '.chr(10); + echo 'Removing lost RTEmagic files from folders inside uploads/: '.LF; foreach($resultArray['lostFiles'] as $key => $value) { $absFileName = t3lib_div::getFileAbsFileName($value); @@ -279,10 +279,10 @@ echo ' ERROR: File "'.$absFileName.'" was not found!'; } } - echo chr(10); + echo LF; } } - } else echo 'Bypassing fixing of double-usages since --AUTOFIX was not "lostFiles"'.chr(10); + } else echo 'Bypassing fixing of double-usages since --AUTOFIX was not "lostFiles"'.LF; } /** Index: typo3/sysext/lowlevel/HOWTO_clean_up_TYPO3_installations.txt =================================================================== --- typo3/sysext/lowlevel/HOWTO_clean_up_TYPO3_installations.txt (revision 7304) +++ typo3/sysext/lowlevel/HOWTO_clean_up_TYPO3_installations.txt (working copy) @@ -149,7 +149,7 @@ // Initialize result array: $resultArray = array( 'message' => $this->cli_help['name']. - chr(10).chr(10). + LF.LF. $this->cli_help['description'], 'headers' => array( 'SOME_ANALYSIS_1' => array('HEADER','DESCRIPTION',VERBOSITY_LEVEL 0-3), Index: typo3/sysext/lowlevel/dbint/index.php =================================================================== --- typo3/sysext/lowlevel/dbint/index.php (revision 7304) +++ typo3/sysext/lowlevel/dbint/index.php (working copy) @@ -366,7 +366,7 @@ list($headerContent,$bodyContent) = $refIndexObj->updateIndex($testOnly); // Output content: - $this->content.=$this->doc->section($headerContent,str_replace(chr(10),'
    ',$bodyContent),0,1); + $this->content.=$this->doc->section($headerContent,str_replace(LF,'
    ',$bodyContent),0,1); } // Output content: Index: typo3/sysext/lowlevel/class.tx_lowlevel_cleaner_core.php =================================================================== --- typo3/sysext/lowlevel/class.tx_lowlevel_cleaner_core.php (revision 7304) +++ typo3/sysext/lowlevel/class.tx_lowlevel_cleaner_core.php (working copy) @@ -139,7 +139,7 @@ // Print Howto: if ($this->cli_isArg('--showhowto')) { $howto = t3lib_div::getUrl(t3lib_extMgm::extPath('lowlevel').'HOWTO_clean_up_TYPO3_installations.txt'); - echo wordwrap($howto,120).chr(10); + echo wordwrap($howto,120).LF; exit; } @@ -263,9 +263,9 @@ if ($detailLevel <= 1) { $this->cli_echo( "*********************************************\n". - $header."\n". + $header.LF. "*********************************************\n"); - $this->cli_echo(wordwrap(trim($res['message'])).chr(10).chr(10)); + $this->cli_echo(wordwrap(trim($res['message'])).LF.LF); } // Traverse headers for output: @@ -276,12 +276,12 @@ if (is_array($res[$key]) && (count($res[$key]) || !$silent)) { // Header and explanaion: - $this->cli_echo('---------------------------------------------'.chr(10),1); - $this->cli_echo('['.$header.']'.chr(10),1); - $this->cli_echo($value[0].' ['.$severity[$value[2]].']'.chr(10),1); - $this->cli_echo('---------------------------------------------'.chr(10),1); + $this->cli_echo('---------------------------------------------'.LF,1); + $this->cli_echo('['.$header.']'.LF,1); + $this->cli_echo($value[0].' ['.$severity[$value[2]].']'.LF,1); + $this->cli_echo('---------------------------------------------'.LF,1); if (trim($value[1])) { - $this->cli_echo('Explanation: '.wordwrap(trim($value[1])).chr(10).chr(10),1); + $this->cli_echo('Explanation: '.wordwrap(trim($value[1])).LF.LF,1); } } @@ -290,10 +290,10 @@ if (count($res[$key])) { if ($this->cli_echo('',1)) { print_r($res[$key]); } } else { - $this->cli_echo('(None)'.chr(10).chr(10)); + $this->cli_echo('(None)'.LF.LF); } } else { - $this->cli_echo($res[$key].chr(10).chr(10)); + $this->cli_echo($res[$key].LF.LF); } } } @@ -362,7 +362,7 @@ ksort($this->recStats[$kk]); } - if ($echoLevel>0) echo chr(10).chr(10); + if ($echoLevel>0) echo LF.LF; // Processing performance statistics: @@ -378,7 +378,7 @@ ); $countRow = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($resSub); $this->performanceStatistics['MySQL_count'][$tableName]=$countRow['count(*)']; - $this->performanceStatistics['CSV'].=chr(10).$tableName.','. + $this->performanceStatistics['CSV'].=LF.$tableName.','. $this->performanceStatistics['genTree_traverse():TraverseTables:']['MySQL'][$tableName].','. $this->performanceStatistics['genTree_traverse():TraverseTables:']['Proc'][$tableName].','. $this->performanceStatistics['MySQL_count'][$tableName]; @@ -432,14 +432,14 @@ } if ($echoLevel>0) - echo chr(10).$accumulatedPath.' ['.$rootID.']'. + echo LF.$accumulatedPath.' ['.$rootID.']'. ($pageRecord['deleted'] ? ' (DELETED)':''). ($this->recStats['versions_published']['pages'][$rootID] ? ' (PUBLISHED)':'') ; if ($echoLevel>1 && $this->recStats['versions_lost_workspace']['pages'][$rootID]) - echo chr(10).' ERROR! This version belongs to non-existing workspace ('.$pageRecord['t3ver_wsid'].')!'; + echo LF.' ERROR! This version belongs to non-existing workspace ('.$pageRecord['t3ver_wsid'].')!'; if ($echoLevel>1 && $this->recStats['versions_inside_versioned_page']['pages'][$rootID]) - echo chr(10).' WARNING! This version is inside an already versioned page or branch!'; + echo LF.' WARNING! This version is inside an already versioned page or branch!'; // Call back: if ($callBack) { @@ -466,17 +466,17 @@ $pt5=t3lib_div::milliseconds(); $count = $GLOBALS['TYPO3_DB']->sql_num_rows($resSub); if ($count) { - if ($echoLevel==2) echo chr(10).' \-'.$tableName.' ('.$count.')'; + if ($echoLevel==2) echo LF.' \-'.$tableName.' ('.$count.')'; } while ($rowSub = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($resSub)) { - if ($echoLevel==3) echo chr(10).' \-'.$tableName.':'.$rowSub['uid']; + if ($echoLevel==3) echo LF.' \-'.$tableName.':'.$rowSub['uid']; // If the rootID represents an "element" or "page" version type, we must check if the record from this table is allowed to belong to this: if ($versionSwapmode=='SWAPMODE:-1' || ($versionSwapmode=='SWAPMODE:0' && !$GLOBALS['TCA'][$tableName]['ctrl']['versioning_followPages'])) { // This is illegal records under a versioned page - therefore not registered in $this->recStats['all'] so they should be orphaned: $this->recStats['illegal_record_under_versioned_page'][$tableName][$rowSub['uid']] = $rowSub['uid']; - if ($echoLevel>1) echo chr(10).' ERROR! Illegal record ('.$tableName.':'.$rowSub['uid'].') under versioned page!'; + if ($echoLevel>1) echo LF.' ERROR! Illegal record ('.$tableName.':'.$rowSub['uid'].') under versioned page!'; } else { $this->recStats['all'][$tableName][$rowSub['uid']] = $rowSub['uid']; @@ -489,11 +489,11 @@ // Check location of records regarding tree root: if (!$GLOBALS['TCA'][$tableName]['ctrl']['rootLevel'] && $rootID==0) { $this->recStats['misplaced_at_rootlevel'][$tableName][$rowSub['uid']] = $rowSub['uid']; - if ($echoLevel>1) echo chr(10).' ERROR! Misplaced record ('.$tableName.':'.$rowSub['uid'].') on rootlevel!'; + if ($echoLevel>1) echo LF.' ERROR! Misplaced record ('.$tableName.':'.$rowSub['uid'].') on rootlevel!'; } if ($GLOBALS['TCA'][$tableName]['ctrl']['rootLevel']==1 && $rootID>0) { $this->recStats['misplaced_inside_tree'][$tableName][$rowSub['uid']] = $rowSub['uid']; - if ($echoLevel>1) echo chr(10).' ERROR! Misplaced record ('.$tableName.':'.$rowSub['uid'].') inside page tree!'; + if ($echoLevel>1) echo LF.' ERROR! Misplaced record ('.$tableName.':'.$rowSub['uid'].') inside page tree!'; } // Traverse plugins: @@ -507,7 +507,7 @@ if (is_array($versions)) { foreach($versions as $verRec) { if (!$verRec['_CURRENT_VERSION']) { - if ($echoLevel==3) echo chr(10).' \-[#OFFLINE VERSION: WS#'.$verRec['t3ver_wsid'].'/Cnt:'.$verRec['t3ver_count'].'] '.$tableName.':'.$verRec['uid'].')'; + if ($echoLevel==3) echo LF.' \-[#OFFLINE VERSION: WS#'.$verRec['t3ver_wsid'].'/Cnt:'.$verRec['t3ver_count'].'] '.$tableName.':'.$verRec['uid'].')'; $this->recStats['all'][$tableName][$verRec['uid']] = $verRec['uid']; // Register deleted: @@ -527,11 +527,11 @@ } if (!isset($this->workspaceIndex[$verRec['t3ver_wsid']])) { $this->recStats['versions_lost_workspace'][$tableName][$verRec['uid']] = $verRec['uid']; - if ($echoLevel>1) echo chr(10).' ERROR! Version ('.$tableName.':'.$verRec['uid'].') belongs to non-existing workspace ('.$verRec['t3ver_wsid'].')!'; + if ($echoLevel>1) echo LF.' ERROR! Version ('.$tableName.':'.$verRec['uid'].') belongs to non-existing workspace ('.$verRec['t3ver_wsid'].')!'; } if ($versionSwapmode) { // In case we are inside a versioned branch, there should not exists versions inside that "branch". $this->recStats['versions_inside_versioned_page'][$tableName][$verRec['uid']] = $verRec['uid']; - if ($echoLevel>1) echo chr(10).' ERROR! This version ('.$tableName.':'.$verRec['uid'].') is inside an already versioned page or branch!'; + if ($echoLevel>1) echo LF.' ERROR! This version ('.$tableName.':'.$verRec['uid'].') is inside an already versioned page or branch!'; } // Traverse plugins: Index: typo3/sysext/lowlevel/class.tx_lowlevel_admin_core.php =================================================================== --- typo3/sysext/lowlevel/class.tx_lowlevel_admin_core.php (revision 7304) +++ typo3/sysext/lowlevel/class.tx_lowlevel_admin_core.php (working copy) @@ -131,7 +131,7 @@ $this->cli_echo("Unknown toolkey, '".$analysisType."'"); break; } - $this->cli_echo("\n"); + $this->cli_echo(LF); } Index: typo3/sysext/opendocs/class.tx_opendocs.php =================================================================== --- typo3/sysext/opendocs/class.tx_opendocs.php (revision 7304) +++ typo3/sysext/opendocs/class.tx_opendocs.php (working copy) @@ -105,7 +105,7 @@ $opendocsMenu[] = $this->renderMenu(); $opendocsMenu[] = ''; - return implode("\n", $opendocsMenu); + return implode(LF, $opendocsMenu); } /** Index: typo3/sysext/sys_action/toolbarmenu/class.tx_sysaction_toolbarmenu.php =================================================================== --- typo3/sysext/sys_action/toolbarmenu/class.tx_sysaction_toolbarmenu.php (revision 7304) +++ typo3/sysext/sys_action/toolbarmenu/class.tx_sysaction_toolbarmenu.php (working copy) @@ -94,7 +94,7 @@ } $actionMenu[] = ''; - return implode("\n", $actionMenu); + return implode(LF, $actionMenu); } else { return ''; } Index: typo3/sysext/rsaauth/sv1/backends/class.tx_rsaauth_cmdline_backend.php =================================================================== --- typo3/sysext/rsaauth/sv1/backends/class.tx_rsaauth_cmdline_backend.php (revision 7304) +++ typo3/sysext/rsaauth/sv1/backends/class.tx_rsaauth_cmdline_backend.php (working copy) @@ -150,7 +150,7 @@ @unlink($privateKeyFile); @unlink($dataFile); - return implode(chr(10), $output); + return implode(LF, $output); } /** Index: typo3/sysext/feedit/view/class.tx_feedit_editpanel.php =================================================================== --- typo3/sysext/feedit/view/class.tx_feedit_editpanel.php (revision 7304) +++ typo3/sysext/feedit/view/class.tx_feedit_editpanel.php (working copy) @@ -123,7 +123,7 @@ $labelTxt = $this->cObj->stdWrap($conf['label'],$conf['label.']); foreach((array) $hiddenFields as $name => $value) { - $hiddenFieldString .= '' . chr(10); + $hiddenFieldString .= '' . LF; } $panel=' Index: typo3/sysext/impexp/class.tx_impexp.php =================================================================== --- typo3/sysext/impexp/class.tx_impexp.php (revision 7304) +++ typo3/sysext/impexp/class.tx_impexp.php (working copy) @@ -1091,7 +1091,7 @@ // Creating XML file from $outputArray: $charset = $this->dat['header']['charset'] ? $this->dat['header']['charset'] : 'iso-8859-1'; - $XML = ''.chr(10); + $XML = ''.LF; $XML.= t3lib_div::array2xml($this->dat,'',0,'T3RecordDocument',0,$options); return $XML; Index: typo3/sysext/lang/lang.php =================================================================== --- typo3/sysext/lang/lang.php (revision 7304) +++ typo3/sysext/lang/lang.php (working copy) @@ -373,7 +373,7 @@ // Add label: switch((string)$kParts[2]) { case '+': // adding - $TCA_DESCR[$table]['columns'][$kParts[0]][$kParts[1]].= chr(10).$lVal; + $TCA_DESCR[$table]['columns'][$kParts[0]][$kParts[1]].= LF.$lVal; break; default: // Substituting: $TCA_DESCR[$table]['columns'][$kParts[0]][$kParts[1]] = $lVal; Index: typo3/sysext/recycler/mod1/index.php =================================================================== --- typo3/sysext/recycler/mod1/index.php (revision 7304) +++ typo3/sysext/recycler/mod1/index.php (working copy) @@ -158,7 +158,7 @@ */ protected function loadStylesheet($fileName) { $fileName = t3lib_div::resolveBackPath($this->doc->backPath . $fileName); - $this->doc->JScode.= "\t" . '' . "\n"; + $this->doc->JScode.= TAB . '' . LF; } /** @@ -169,7 +169,7 @@ */ protected function loadJavaScript($fileName) { $fileName = t3lib_div::resolveBackPath($this->doc->backPath . $fileName); - $this->doc->JScode.= "\t" . '' . "\n"; + $this->doc->JScode.= TAB . '' . LF; } /** Index: typo3/sysext/tsconfig_help/mod1/index.php =================================================================== --- typo3/sysext/tsconfig_help/mod1/index.php (revision 7304) +++ typo3/sysext/tsconfig_help/mod1/index.php (working copy) @@ -541,10 +541,10 @@ $node = $vals[$id]; // sanity check - if ($sectionHeader < 0) die ('Malformed XML (header-rows)'."\n"); - if ($sectionRow < 0) die ('Malformed XML (row)'."\n"); - if ($sectionCell < 0) die ('Malformed XML (cell)'."\n"); - if ($sectionP < 0) die ('Malformed XML (P)'."\n"); + if ($sectionHeader < 0) die ('Malformed XML (header-rows)'.LF); + if ($sectionRow < 0) die ('Malformed XML (row)'.LF); + if ($sectionCell < 0) die ('Malformed XML (cell)'.LF); + if ($sectionP < 0) die ('Malformed XML (P)'.LF); switch ($node['type']) { case 'open': Index: typo3/sysext/t3editor/classes/class.tx_t3editor.php =================================================================== --- typo3/sysext/t3editor/classes/class.tx_t3editor.php (revision 7304) +++ typo3/sysext/t3editor/classes/class.tx_t3editor.php (working copy) @@ -144,11 +144,11 @@ $content .= t3lib_div::wrapJS( 'T3editor = T3editor || {};' . - 'T3editor.lang = ' . json_encode($this->getJavaScriptLabels()) .';' . chr(10). - 'T3editor.PATH_t3e = "' . $GLOBALS['BACK_PATH'] . t3lib_extmgm::extRelPath('t3editor') . '"; ' . chr(10). - 'T3editor.URL_typo3 = "' . htmlspecialchars(t3lib_div::getIndpEnv('TYPO3_SITE_URL') . TYPO3_mainDir) . '"; ' .chr(10). - 'T3editor.template = '. $this->getPreparedTemplate() .';' .chr(10). - 'T3editor.parserfile = ' . $this->getParserfileByMode($this->mode) . ';' .chr(10). + 'T3editor.lang = ' . json_encode($this->getJavaScriptLabels()) .';' . LF. + 'T3editor.PATH_t3e = "' . $GLOBALS['BACK_PATH'] . t3lib_extmgm::extRelPath('t3editor') . '"; ' . LF. + 'T3editor.URL_typo3 = "' . htmlspecialchars(t3lib_div::getIndpEnv('TYPO3_SITE_URL') . TYPO3_mainDir) . '"; ' .LF. + 'T3editor.template = '. $this->getPreparedTemplate() .';' .LF. + 'T3editor.parserfile = ' . $this->getParserfileByMode($this->mode) . ';' .LF. 'T3editor.stylesheet = ' . $this->getStylesheetByMode($this->mode) . ';' ); } @@ -168,7 +168,7 @@ ) ); $T3Editor_template = addslashes($T3Editor_template); - $T3Editor_template = str_replace("\n", "' + '", $T3Editor_template); + $T3Editor_template = str_replace(LF, "' + '", $T3Editor_template); return '\'' . $T3Editor_template . '\''; } Index: typo3/wizard_table.php =================================================================== --- typo3/wizard_table.php (revision 7304) +++ typo3/wizard_table.php (working copy) @@ -359,7 +359,7 @@ if ($this->inputStyle) { $cells[]='doc->formWidth(20).' name="TABLE[c]['.(($k+1)*2).']['.(($a+1)*2).']" value="'.htmlspecialchars($cellContent).'" />'; } else { - $cellContent=preg_replace('//i',chr(10),$cellContent); + $cellContent=preg_replace('//i',LF,$cellContent); $cells[]=''; } @@ -588,7 +588,7 @@ while(list($a)=each($this->TABLECFG['c'])) { reset($this->TABLECFG['c'][$a]); while(list($b)=each($this->TABLECFG['c'][$a])) { - $this->TABLECFG['c'][$a][$b] = str_replace(chr(10),'
    ',str_replace(chr(13),'',$this->TABLECFG['c'][$a][$b])); + $this->TABLECFG['c'][$a][$b] = str_replace(LF,'
    ',str_replace(CR,'',$this->TABLECFG['c'][$a][$b])); } } } @@ -617,7 +617,7 @@ } // Finally, implode the lines into a string: - $bodyText = implode(chr(10),$inLines); + $bodyText = implode(LF,$inLines); // Return the configuration code: return $bodyText; @@ -634,7 +634,7 @@ function cfgString2CfgArray($cfgStr,$cols) { // Explode lines in the configuration code - each line is a table row. - $tLines=explode(chr(10),$cfgStr); + $tLines=explode(LF,$cfgStr); // Setting number of columns if (!$cols && trim($tLines[0])) { // auto... Index: typo3/init.php =================================================================== --- typo3/init.php (revision 7304) +++ typo3/init.php (working copy) @@ -247,13 +247,13 @@ } else { echo "The supplied 'cliKey' was not valid. Please use one of the available from this list:\n\n"; print_r(array_keys($TYPO3_CONF_VARS['SC_OPTIONS']['GLOBAL']['cliKeys'])); - echo "\n"; + echo LF; exit; } } else { echo "Please supply a 'cliKey' as first argument. The following are available:\n\n"; print_r($TYPO3_CONF_VARS['SC_OPTIONS']['GLOBAL']['cliKeys']); - echo "\n"; + echo LF; exit; } } @@ -431,9 +431,9 @@ if (!strcmp($_SERVER['argv'][1],'status')) { echo "Status of TYPO3 CLI script:\n\n"; echo "Username [uid]: ".$BE_USER->user['username']." [".$BE_USER->user['uid']."]\n"; - echo "Database: ".TYPO3_db."\n"; - echo "PATH_site: ".PATH_site."\n"; - echo "\n"; + echo "Database: ".TYPO3_db.LF; + echo "PATH_site: ".PATH_site.LF; + echo LF; exit; } } Index: typo3/view_help.php =================================================================== --- typo3/view_help.php (revision 7304) +++ typo3/view_help.php (working copy) @@ -538,7 +538,7 @@ global $TCA,$BE_USER,$TCA_DESCR; // Split references by comma or linebreak - $items = preg_split('/[,' . chr(10) . ']/', $value); + $items = preg_split('/[,' . LF . ']/', $value); $lines = array(); foreach($items as $val) { @@ -588,7 +588,7 @@ // Splitting: $imgArray = t3lib_div::trimExplode(',', $images, 1); if (count($imgArray)) { - $descrArray = explode(chr(10),$descr,count($imgArray)); + $descrArray = explode(LF,$descr,count($imgArray)); foreach($imgArray as $k => $image) { $descr = $descrArray[$k]; Index: typo3/backend.php =================================================================== --- typo3/backend.php (revision 7304) +++ typo3/backend.php (working copy) @@ -336,7 +336,7 @@ $pathTYPO3 = t3lib_div::dirname(t3lib_div::getIndpEnv('SCRIPT_NAME')).'/'; $goToModuleSwitch = $this->moduleMenu->getGotoModuleJavascript(); - $moduleFramesHelper = implode(chr(10), $this->moduleMenu->getFsMod()); + $moduleFramesHelper = implode(LF, $this->moduleMenu->getFsMod()); // If another page module was specified, replace the default Page module with the new one $newPageModule = trim($GLOBALS['BE_USER']->getTSConfigVal('options.overridePageModule')); Index: typo3/alt_main.php =================================================================== --- typo3/alt_main.php (revision 7304) +++ typo3/alt_main.php (working copy) @@ -134,7 +134,7 @@ $pt3 = t3lib_div::dirname(t3lib_div::getIndpEnv('SCRIPT_NAME')).'/'; $goToModule_switch = $this->alt_menuObj->topMenu($this->loadModules->modules,0,"",4); - $fsMod = implode(chr(10),$this->alt_menuObj->fsMod); + $fsMod = implode(LF,$this->alt_menuObj->fsMod); // If another page module was specified, replace the default Page module with the new one $newPageModule = trim($GLOBALS['BE_USER']->getTSConfigVal('options.overridePageModule')); @@ -298,7 +298,7 @@ var acc; for (i in obj) { if (obj[i]) { - acc+=i+": "+obj[i]+"\n"; + acc+=i+": "+obj[i]+LF; } } alert("Object: "+name+"\n\n"+acc); Index: typo3/mod/tools/em/class.em_index.php =================================================================== --- typo3/mod/tools/em/class.em_index.php (revision 7304) +++ typo3/mod/tools/em/class.em_index.php (working copy) @@ -767,7 +767,7 @@ if(count($extensions)) { $lines[]='
    '; $lines[]=''.htmlspecialchars($this->listOrderTitle($this->MOD_SETTINGS['listOrder'],$catName)).''; - $lines[] = implode(chr(10),$extensions); + $lines[] = implode(LF,$extensions); } } } @@ -828,7 +828,7 @@ if(count($extensions)) { $lines[]='
    '; $lines[]=''.htmlspecialchars($this->listOrderTitle($this->MOD_SETTINGS['listOrder'],$catName)).''; - $lines[] = implode(chr(10),$extensions); + $lines[] = implode(LF,$extensions); } } @@ -838,7 +838,7 @@ @@ -966,7 +966,7 @@ $content.= ' - '.implode(chr(10),$lines).'
    '; + '.implode(LF,$lines).'
    '; $content .= '
    '.$this->browseLinks(); $content.= '

    '.$this->securityHint; $content .= '

    ' . $GLOBALS['LANG']->getLL('privacy_notice_header') . @@ -2340,7 +2340,7 @@ if(isset($submittedContent['file']) && !$GLOBALS['TYPO3_CONF_VARS']['EXT']['noEdit']) { // Check referer here? $oldFileContent = t3lib_div::getUrl($editFile); if($oldFileContent != $submittedContent['file']) { - $oldMD5 = md5(str_replace(chr(13),'',$oldFileContent)); + $oldMD5 = md5(str_replace(CR,'',$oldFileContent)); $info .= sprintf( $GLOBALS['LANG']->getLL('ext_details_md5_previous'), '' . $oldMD5 . '' @@ -2359,13 +2359,13 @@ '' . substr($editFile, strlen($absPath)) . ' (' . t3lib_div::formatSize(filesize($editFile)) . ')
    ' ); - $fileMD5 = md5(str_replace(chr(13),'',$fileContent)); + $fileMD5 = md5(str_replace(CR,'',$fileContent)); $info .= sprintf( $GLOBALS['LANG']->getLL('ext_details_md5_current'), '' . $fileMD5 . '' ) . '
    '; if($saveFlag) { - $saveMD5 = md5(str_replace(chr(13),'',$submittedContent['file'])); + $saveMD5 = md5(str_replace(CR,'',$submittedContent['file'])); $info .= sprintf( $GLOBALS['LANG']->getLL('ext_details_md5_submitted'), '' . $saveMD5 . '' @@ -3236,10 +3236,10 @@ return nl2br(trim((is_array($techInfo['tables']) ? ($tableHeader ? "\n\n" . $GLOBALS['LANG']->getLL('extDumpTables_tables') . "\n" : '') . - implode(chr(10), $techInfo['tables']) : '') . + implode(LF, $techInfo['tables']) : '') . (is_array($techInfo['static']) ? "\n\n" . $GLOBALS['LANG']->getLL('extBackup_static_tables') . "\n" . - implode(chr(10), $techInfo['static']) : ''). + implode(LF, $techInfo['static']) : ''). (is_array($techInfo['fields']) ? "\n\n" . $GLOBALS['LANG']->getLL('extInfoArray_additional_fields') . "\n" . implode('
    ', $techInfo['fields']) : ''))); @@ -4179,7 +4179,7 @@ if (preg_match('/\n[[:space:]]*class[[:space:]]*([[:alnum:]_]+)([[:alnum:][:space:]_]*)/',$fContent,$reg)) { // Find classes: - $lines = explode(chr(10),$fContent); + $lines = explode(LF,$fContent); foreach($lines as $l) { $line = trim($l); unset($reg); @@ -4240,7 +4240,7 @@ * @see writeTYPO3_MOD_PATH() */ function modConfFileAnalysis($confFilePath) { - $lines = explode(chr(10),t3lib_div::getUrl($confFilePath)); + $lines = explode(LF,t3lib_div::getUrl($confFilePath)); $confFileInfo = array(); $confFileInfo['lines'] = $lines; $reg = array(); @@ -4405,7 +4405,7 @@ } else $errors[] = $GLOBALS['LANG']->getLL('rmExtDir_error_unallowed_path') . ' ' . $removePath; // Return errors if any: - return implode(chr(10),$errors); + return implode(LF,$errors); } /** @@ -4551,7 +4551,7 @@ * @see modConfFileAnalysis() */ function writeTYPO3_MOD_PATH($confFilePath,$type,$mP) { - $lines = explode(chr(10),t3lib_div::getUrl($confFilePath)); + $lines = explode(LF,t3lib_div::getUrl($confFilePath)); $confFileInfo = array(); $confFileInfo['lines'] = $lines; $reg = array(); @@ -4585,7 +4585,7 @@ } if ($flag_B && $flag_M) { - t3lib_div::writeFile($confFilePath,implode(chr(10),$lines)); + t3lib_div::writeFile($confFilePath,implode(LF,$lines)); return sprintf($GLOBALS['LANG']->getLL('writeModPath_ok'), substr($confFilePath, strlen(PATH_site))); } elseif ($flag_Dispatch){ @@ -4743,7 +4743,7 @@ $EM_CONF[$_EXTKEY] = '.$this->arrayToCode($EM_CONF, 0).'; ?>'; - return str_replace(chr(13), '', $code); + return str_replace(CR, '', $code); } /** @@ -4755,17 +4755,17 @@ * @return unknown */ function arrayToCode($array, $level=0) { - $lines = 'array('.chr(10); + $lines = 'array('.LF; $level++; foreach($array as $k => $v) { if(strlen($k) && is_array($v)) { - $lines .= str_repeat(chr(9),$level)."'".$k."' => ".$this->arrayToCode($v, $level); + $lines .= str_repeat(TAB,$level)."'".$k."' => ".$this->arrayToCode($v, $level); } elseif(strlen($k)) { - $lines .= str_repeat(chr(9),$level)."'".$k."' => ".(t3lib_div::testInt($v) ? intval($v) : "'".t3lib_div::slashJS(trim($v),1)."'").','.chr(10); + $lines .= str_repeat(TAB,$level)."'".$k."' => ".(t3lib_div::testInt($v) ? intval($v) : "'".t3lib_div::slashJS(trim($v),1)."'").','.LF; } } - $lines .= str_repeat(chr(9),$level-1).')'.($level-1==0 ? '':','.chr(10)); + $lines .= str_repeat(TAB,$level-1).')'.($level-1==0 ? '':','.LF); return $lines; } @@ -4816,7 +4816,7 @@ 'content' => t3lib_div::getUrl($file) ); if (t3lib_div::inList('php,inc',strtolower($fI['extension']))) { - $uploadArray['FILES'][$relFileName]['codelines']=count(explode(chr(10),$uploadArray['FILES'][$relFileName]['content'])); + $uploadArray['FILES'][$relFileName]['codelines']=count(explode(LF,$uploadArray['FILES'][$relFileName]['content'])); $uploadArray['misc']['codelines']+=$uploadArray['FILES'][$relFileName]['codelines']; $uploadArray['misc']['codebytes']+=$uploadArray['FILES'][$relFileName]['size']; @@ -5664,7 +5664,7 @@ } // Return result: - return implode(chr(10).chr(10).chr(10),$tables); + return implode(LF.LF.LF,$tables); } /** @@ -5688,9 +5688,9 @@ $header = $this->dumpTableHeader($table,$dbFields[$table],1); $insertStatements = $this->dumpTableContent($table,$dbFields[$table]['fields']); - $out.= $dHeader.chr(10).chr(10).chr(10). - $header.chr(10).chr(10).chr(10). - $insertStatements.chr(10).chr(10).chr(10); + $out.= $dHeader.LF.LF.LF. + $header.LF.LF.LF. + $insertStatements.LF.LF.LF; } else { die($GLOBALS['LANG']->getLL('dumpStaticTables_table_not_found')); } @@ -5746,7 +5746,7 @@ # '.($dropTableIfExists ? 'DROP TABLE IF EXISTS '.$table.'; ' : '').'CREATE TABLE '.$table.' ( -'.implode(','.chr(10),$lines).' +'.implode(','.LF,$lines).' );' ); } @@ -5787,7 +5787,7 @@ $GLOBALS['TYPO3_DB']->sql_free_result($result); // Implode lines and return: - return implode(chr(10),$lines); + return implode(LF,$lines); } /** @@ -6183,11 +6183,11 @@ } $warn = ''; if (strcmp(serialize($currentMD5Array), serialize($serverMD5Array))) { - $warn = ''.$GLOBALS['TBE_TEMPLATE']->rfw('
    '.$name.': '.$LANG->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:msg_warn_diff').'').''."\n"; + $warn = ''.$GLOBALS['TBE_TEMPLATE']->rfw('
    '.$name.': '.$LANG->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:msg_warn_diff').'').''.LF; if ($this->MOD_SETTINGS['display_files'] == 1) { $affectedFiles = $this->findMD5ArrayDiff($serverMD5Array,$currentMD5Array); if (count($affectedFiles)) { - $warn .= ''.$LANG->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:msg_modified').'
    '.$GLOBALS['TBE_TEMPLATE']->rfw(implode('
    ',$affectedFiles)).''."\n"; + $warn .= ''.$LANG->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:msg_modified').'
    '.$GLOBALS['TBE_TEMPLATE']->rfw(implode('
    ',$affectedFiles)).''.LF; } } } @@ -6197,9 +6197,9 @@ ''.$data[EM_CONF][version].''. ''.$lastversion.''. ''.$this->typeLabels[$data['type']].(strlen($data['doubleInstall'])>1?' '.$GLOBALS['TBE_TEMPLATE']->rfw($extInfo['doubleInstall']).'':'').''. -''.$comment.''."\n". +''.$comment.''.LF. $warn. -'
    '."\n"; +'
    '.LF; } } Index: t3lib/class.t3lib_readmail.php =================================================================== --- t3lib/class.t3lib_readmail.php (revision 7304) +++ t3lib/class.t3lib_readmail.php (working copy) @@ -368,7 +368,7 @@ function extractMailHeader($content,$limit=0) { if ($limit) $content = substr($content,0,$limit); - $lines=explode(chr(10),ltrim($content)); + $lines=explode(LF,ltrim($content)); $headers=array(); $p=''; while(list($k,$str)=each($lines)) { @@ -386,7 +386,7 @@ } unset($lines[$k]); } - if (!$limit) $headers['CONTENT']=ltrim(implode(chr(10),$lines)); + if (!$limit) $headers['CONTENT']=ltrim(implode(LF,$lines)); return $headers; } Index: t3lib/class.gzip_encode.php =================================================================== --- t3lib/class.gzip_encode.php (revision 7304) +++ t3lib/class.gzip_encode.php (working copy) @@ -225,7 +225,7 @@ // By Kasper Skaarhoj, start if ($outputCompressedSizes) { - $contents.=chr(10).""; + $contents.=LF.""; $size = strlen($contents); // Must set again! } // By Kasper Skaarhoj, end Index: t3lib/class.t3lib_admin.php =================================================================== --- t3lib/class.t3lib_admin.php (revision 7304) +++ t3lib/class.t3lib_admin.php (working copy) @@ -160,7 +160,7 @@ // Build HTML output: if ($this->genTree_makeHTML) { - $this->genTree_HTML.=chr(10).'
    '; + $this->genTree_HTML.=LF.'
    '; $PM = 'join'; $LN = ($a==$c)?'blank':'line'; $BTM = ($a==$c)?'bottom':''; @@ -250,7 +250,7 @@ // Build HTML output: if ($this->genTree_makeHTML) { - $this->genTree_HTML.=chr(10).'
    '; + $this->genTree_HTML.=LF.'
    '; $PM = 'join'; $LN = ($a==$c)?'blank':'line'; $BTM = ($a==$c)?'bottom':''; Index: t3lib/class.t3lib_befunc.php =================================================================== --- t3lib/class.t3lib_befunc.php (revision 7304) +++ t3lib/class.t3lib_befunc.php (working copy) @@ -1336,7 +1336,7 @@ } // Parsing the page TS-Config (or getting from cache) - $pageTS = implode(chr(10) . '[GLOBAL]' . chr(10), $TSdataArray); + $pageTS = implode(LF . '[GLOBAL]' . LF, $TSdataArray); if ($GLOBALS['TYPO3_CONF_VARS']['BE']['TSconfigConditions']) { /* @var $parseObj t3lib_TSparser_TSconfig */ $parseObj = t3lib_div::makeInstance('t3lib_TSparser_TSconfig'); @@ -1401,7 +1401,7 @@ if (count($set)) { // Get page record and TS config lines $pRec = t3lib_befunc::getRecord('pages', $id); - $TSlines = explode(chr(10), $pRec['TSconfig']); + $TSlines = explode(LF, $pRec['TSconfig']); $TSlines = array_reverse($TSlines); // Reset the set of changes. reset($set); @@ -1424,7 +1424,7 @@ $TSlines = array_reverse($TSlines); // store those changes - $TSconf = implode(chr(10), $TSlines); + $TSconf = implode(LF, $TSlines); $GLOBALS['TYPO3_DB']->exec_UPDATEquery('pages', 'uid='.intval($id), array('TSconfig' => $TSconf)); } @@ -2926,7 +2926,7 @@ } } - $content = implode(chr(10), $signals); + $content = implode(LF, $signals); t3lib_BEfunc::setUpdateSignal(); // for backwards compatibility, should be replaced return $content; @@ -4366,7 +4366,7 @@ */ public static function processParams($params) { $paramArr = array(); - $lines = explode(chr(10), $params); + $lines = explode(LF, $params); while(list(,$val) = each($lines)) { $val = trim($val); if ($val) { Index: t3lib/class.t3lib_formmail.php =================================================================== --- t3lib/class.t3lib_formmail.php (revision 7304) +++ t3lib/class.t3lib_formmail.php (working copy) @@ -144,14 +144,14 @@ reset($V); while (list($key,$val)=each($V)) { if (!t3lib_div::inList($this->reserved_names,$key)) { - $space = (strlen($val)>60)?chr(10):''; - $val = (is_array($val) ? implode($val,chr(10)) : $val); + $space = (strlen($val)>60)?LF:''; + $val = (is_array($val) ? implode($val,LF) : $val); // convert form data from renderCharset to mail charset (HTML may use entities) $Plain_val = ($convCharset && strlen($val)) ? $GLOBALS['TSFE']->csConvObj->conv($val,$GLOBALS['TSFE']->renderCharset,$this->charset,0) : $val; $HTML_val = ($convCharset && strlen($val)) ? $GLOBALS['TSFE']->csConvObj->conv(htmlspecialchars($val),$GLOBALS['TSFE']->renderCharset,$this->charset,1) : htmlspecialchars($val); - $Plain_content.= strtoupper($key).': '.$space.$Plain_val."\n".$space; + $Plain_content.= strtoupper($key).': '.$space.$Plain_val.LF.$space; $HTML_content.= ''.strtoupper($key).''.nl2br($HTML_val).' '; } } Index: t3lib/class.t3lib_userauthgroup.php =================================================================== --- t3lib/class.t3lib_userauthgroup.php (revision 7304) +++ t3lib/class.t3lib_userauthgroup.php (working copy) @@ -1201,7 +1201,7 @@ // Check include lines. $this->TSdataArray = t3lib_TSparser::checkIncludeLines_array($this->TSdataArray); - $this->userTS_text = implode(chr(10).'[GLOBAL]'.chr(10),$this->TSdataArray); // Imploding with "[global]" will make sure that non-ended confinements with braces are ignored. + $this->userTS_text = implode(LF.'[GLOBAL]'.LF,$this->TSdataArray); // Imploding with "[global]" will make sure that non-ended confinements with braces are ignored. if ($GLOBALS['TYPO3_CONF_VARS']['BE']['TSconfigConditions'] && !$this->userTS_dontGetCached) { // Perform TS-Config parsing with condition matching @@ -1459,12 +1459,12 @@ function addTScomment($str) { $delimiter = '# ***********************************************'; - $out = $delimiter.chr(10); - $lines = t3lib_div::trimExplode(chr(10),$str); + $out = $delimiter.LF; + $lines = t3lib_div::trimExplode(LF,$str); foreach($lines as $v) { - $out.= '# '.$v.chr(10); + $out.= '# '.$v.LF; } - $out.= $delimiter.chr(10); + $out.= $delimiter.LF; return $out; } @@ -1809,7 +1809,7 @@ while($testRows = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res)) { $theData = unserialize($testRows['log_data']); $email_body.= date($GLOBALS['TYPO3_CONF_VARS']['SYS']['ddmmyy'].' '.$GLOBALS['TYPO3_CONF_VARS']['SYS']['hhmm'],$testRows['tstamp']).': '.@sprintf($testRows['details'],''.$theData[0],''.$theData[1],''.$theData[2]); - $email_body.= chr(10); + $email_body.= LF; } mail( $email, $subject, Index: t3lib/class.t3lib_pagerenderer.php =================================================================== --- t3lib/class.t3lib_pagerenderer.php (revision 7304) +++ t3lib/class.t3lib_pagerenderer.php (working copy) @@ -136,12 +136,12 @@ $this->backPath = isset($backPath) ? $backPath : $GLOBALS['BACK_PATH']; $this->inlineJavascriptWrap = array( - '' . chr(10) + '' . LF ); $this->inlineCssWrap = array( - '' . chr(10) + '' . LF ); } @@ -656,7 +656,7 @@ public function addJsInlineCode($name, $block, $compress = TRUE, $forceOnTop = FALSE) { if (!isset($this->jsInline[$name])) { $this->jsInline[$name] = array ( - 'code' => $block . chr(10), + 'code' => $block . LF, 'section' => self::PART_HEADER, 'compress' => $compress, 'forceOnTop' => $forceOnTop @@ -676,7 +676,7 @@ public function addJsFooterInlineCode($name, $block, $compress = TRUE, $forceOnTop = FALSE) { if (!isset($this->jsInline[$name])) { $this->jsInline[$name] = array ( - 'code' => $block . chr(10), + 'code' => $block . LF, 'section' => self::PART_FOOTER, 'compress' => $compress, 'forceOnTop' => $forceOnTop @@ -996,7 +996,7 @@ $this->doConcatenate(); } - $metaTags = implode(chr(10), $this->metaTags); + $metaTags = implode(LF, $this->metaTags); if (count($this->cssFiles)) { foreach ($this->cssFiles as $file => $properties) { @@ -1006,9 +1006,9 @@ $tag = str_replace('|', $tag, $properties['allWrap']); } if ($properties['forceOnTop']) { - $cssFiles = $tag . chr(10) . $cssFiles; + $cssFiles = $tag . LF . $cssFiles; } else { - $cssFiles .= chr(10) . $tag; + $cssFiles .= LF . $tag; } } } @@ -1017,9 +1017,9 @@ foreach ($this->cssInline as $name => $properties) { if ($properties['forceOnTop']) { - $cssInline = '/*' . htmlspecialchars($name) . '*/' . chr(10) . $properties['code'] . chr(10) . $cssInline; + $cssInline = '/*' . htmlspecialchars($name) . '*/' . LF . $properties['code'] . LF . $cssInline; } else { - $cssInline .= '/*' . htmlspecialchars($name) . '*/' . chr(10) . $properties['code'] . chr(10); + $cssInline .= '/*' . htmlspecialchars($name) . '*/' . LF . $properties['code'] . LF; } } $cssInline = $this->inlineCssWrap[0] . $cssInline . $this->inlineCssWrap[1]; @@ -1037,15 +1037,15 @@ } if ($properties['forceOnTop']) { if ($properties['section'] === self::PART_HEADER) { - $jsLibs = $tag . chr(10) . $jsLibs; + $jsLibs = $tag . LF . $jsLibs; } else { - $jsFooterLibs = $tag . chr(10) . $jsFooterLibs; + $jsFooterLibs = $tag . LF . $jsFooterLibs; } } else { if ($properties['section'] === self::PART_HEADER) { - $jsLibs .= chr(10) . $tag; + $jsLibs .= LF . $tag; } else { - $jsFooterLibs .= chr(10) . $tag; + $jsFooterLibs .= LF . $tag; } } @@ -1061,15 +1061,15 @@ } if ($properties['forceOnTop']) { if ($properties['section'] === self::PART_HEADER) { - $jsFiles = $tag . chr(10) . $jsFiles; + $jsFiles = $tag . LF . $jsFiles; } else { - $jsFooterFiles = $tag . chr(10) . $jsFooterFiles; + $jsFooterFiles = $tag . LF . $jsFooterFiles; } } else { if ($properties['section'] === self::PART_HEADER) { - $jsFiles .= chr(10) . $tag; + $jsFiles .= LF . $tag; } else { - $jsFooterFiles .= chr(10) . $tag; + $jsFooterFiles .= LF . $tag; } } } @@ -1079,15 +1079,15 @@ foreach ($this->jsInline as $name => $properties) { if ($properties['forceOnTop']) { if ($properties['section'] === self::PART_HEADER) { - $jsInline = '/*' . htmlspecialchars($name) . '*/' . chr(10) . $properties['code'] . chr(10) . $jsInline; + $jsInline = '/*' . htmlspecialchars($name) . '*/' . LF . $properties['code'] . LF . $jsInline; } else { - $jsFooterInline = '/*' . htmlspecialchars($name) . '*/' . chr(10) . $properties['code'] . chr(10) . $jsFooterInline; + $jsFooterInline = '/*' . htmlspecialchars($name) . '*/' . LF . $properties['code'] . LF . $jsFooterInline; } } else { if ($properties['section'] === self::PART_HEADER) { - $jsInline .= '/*' . htmlspecialchars($name) . '*/' . chr(10) . $properties['code'] . chr(10); + $jsInline .= '/*' . htmlspecialchars($name) . '*/' . LF . $properties['code'] . LF; } else { - $jsFooterInline .= '/*' . htmlspecialchars($name) . '*/' . chr(10) . $properties['code'] . chr(10); + $jsFooterInline .= '/*' . htmlspecialchars($name) . '*/' . LF . $properties['code'] . LF; } } } @@ -1108,7 +1108,7 @@ $template = t3lib_div::getURL($templateFile); if ($this->removeEmptyLinesFromTemplate) { - $template = strtr($template, array(chr(10) => '', chr(13) => '')); + $template = strtr($template, array(LF => '', CR => '')); } if ($part != self::PART_COMPLETE) { $templatePart = explode('###BODY###', $template); @@ -1116,11 +1116,11 @@ } if ($this->moveJsFromHeaderToFooter) { - $jsFooterLibs = $jsLibs . chr(10) . $jsFooterLibs; + $jsFooterLibs = $jsLibs . LF . $jsFooterLibs; $jsLibs = ''; - $jsFooterFiles = $jsFiles . chr(10) . $jsFooterFiles; + $jsFooterFiles = $jsFiles . LF . $jsFooterFiles; $jsFiles = ''; - $jsFooterInline = $jsInline . chr(10) . $jsFooterInline; + $jsFooterInline = $jsInline . LF . $jsFooterInline; $jsInline = ''; } @@ -1129,7 +1129,7 @@ 'HTMLTAG' => $this->htmlTag, 'HEADTAG' => $this->headTag, 'METACHARSET' => $this->charSet ? str_replace('|', htmlspecialchars($this->charSet), $this->metaCharsetTag) : '', - 'INLINECOMMENT' => $this->inlineComments ? chr(10) . chr(10) . '' . chr(10) . chr(10) : '', + 'INLINECOMMENT' => $this->inlineComments ? LF . LF . '' . LF . LF : '', 'BASEURL' => $this->baseUrl ? str_replace('|', $this->baseUrl, $this->baseUrlTag) : '', 'SHORTCUT' => $this->favIcon ? sprintf($this->shortcutTag, htmlspecialchars($this->favIcon), $this->iconMimeType) : '', 'CSS_INCLUDE' => $cssFiles, @@ -1139,8 +1139,8 @@ 'JS_LIBS' => $jsLibs, 'TITLE' => $this->title ? str_replace('|', htmlspecialchars($this->title), $this->titleTag) : '', 'META' => $metaTags, - 'HEADERDATA' => $this->headerData ? implode(chr(10), $this->headerData) : '', - 'FOOTERDATA' => $this->footerData ? implode(chr(10), $this->footerData) : '', + 'HEADERDATA' => $this->headerData ? implode(LF, $this->headerData) : '', + 'FOOTERDATA' => $this->footerData ? implode(LF, $this->footerData) : '', 'JS_LIBS_FOOTER' => $jsFooterLibs, 'JS_INCLUDE_FOOTER' => $jsFooterFiles, 'JS_INLINE_FOOTER' => $jsFooterInline, @@ -1162,7 +1162,7 @@ $out = ''; if ($this->addPrototype) { - $out .= '' . chr(10); + $out .= '' . LF; unset($this->jsFiles[$this->backPath . 'contrib/prototype/prototype.js']); } @@ -1182,21 +1182,21 @@ $moduleLoadString = '?load=' . implode(',', $mods); } - $out .= '' . chr(10); + $out .= '' . LF; unset($this->jsFiles[$this->backPath . 'contrib/scriptaculous/scriptaculous.js' . $moduleLoadString]); } // include extCore if ($this->addExtCore) { - $out .= '' . chr(10); + $out .= '' . LF; unset($this->jsFiles[$this->backPath . 'contrib/extjs/ext-core' . ($this->enableExtCoreDebug ? '-debug' : '') . '.js']); } // include extJS if ($this->addExtJS) { // use the base adapter all the time - $out .= '' . chr(10); - $out .= '' . chr(10); + $out .= '' . LF; + $out .= '' . LF; // add extJS localization $localeMap = $this->csConvObj->isoArray; // load standard ISO mapping and modify for use with ExtJS @@ -1211,7 +1211,7 @@ // TODO autoconvert file from UTF8 to current BE charset if necessary!!!! $extJsLocaleFile = 'contrib/extjs/locale/ext-lang-' . $extJsLang . '.js'; if (file_exists(PATH_typo3 . $extJsLocaleFile)) { - $out .= '' . chr(10); + $out .= '' . LF; } @@ -1245,10 +1245,10 @@ $out .= $this->inlineJavascriptWrap[0] . ' Ext.ns("TYPO3"); - Ext.BLANK_IMAGE_URL = "' . htmlspecialchars(t3lib_div::locationHeaderUrl($this->backPath . 'gfx/clear.gif')) . '";' . chr(10) . + Ext.BLANK_IMAGE_URL = "' . htmlspecialchars(t3lib_div::locationHeaderUrl($this->backPath . 'gfx/clear.gif')) . '";' . LF . $inlineSettings . 'Ext.onReady(function() {' . - ($this->enableExtJSQuickTips ? 'Ext.QuickTips.init();' . chr(10) : '') . $code . + ($this->enableExtJSQuickTips ? 'Ext.QuickTips.init();' . LF : '') . $code . ' });' . $this->inlineJavascriptWrap[1]; unset ($this->extOnReadyCode); @@ -1342,7 +1342,7 @@ $error = ''; $this->jsInline[$name]['code'] = t3lib_div::minifyJavaScript($properties['code'], $error); if ($error) { - $this->compressError .= 'Error with minify JS Inline Block "' . $name . '": ' . $error . chr(10); + $this->compressError .= 'Error with minify JS Inline Block "' . $name . '": ' . $error . LF; } } } Index: t3lib/class.t3lib_tstemplate.php =================================================================== --- t3lib/class.t3lib_tstemplate.php (revision 7304) +++ t3lib/class.t3lib_tstemplate.php (working copy) @@ -616,7 +616,7 @@ 'title'=>$row['title'], 'uid'=>$row['uid'], 'pid'=>$row['pid'], - 'configLines' => substr_count($row['config'], chr(10))+1 + 'configLines' => substr_count($row['config'], LF)+1 ); // Adding the content of the fields constants (Constants), config (Setup) and editorcfg (Backend Editor Configuration) to the internal arrays. @@ -1012,7 +1012,7 @@ } // Parsing the user TS (or getting from cache) $TSdataArray = t3lib_TSparser::checkIncludeLines_array($TSdataArray); - $userTS = implode(chr(10).'[GLOBAL]'.chr(10),$TSdataArray); + $userTS = implode(LF.'[GLOBAL]'.LF,$TSdataArray); $parseObj = t3lib_div::makeInstance('t3lib_TSparser'); $parseObj->parse($userTS); Index: t3lib/class.t3lib_refindex.php =================================================================== --- t3lib/class.t3lib_refindex.php (revision 7304) +++ t3lib/class.t3lib_refindex.php (working copy) @@ -715,7 +715,7 @@ // Return errors if any: if (count($tce->errorLog)) { - return chr(10).'TCEmain:'.implode(chr(10).'TCEmain:',$tce->errorLog); + return LF.'TCEmain:'.implode(LF.'TCEmain:',$tce->errorLog); } } } @@ -1007,9 +1007,9 @@ $headerContent = $testOnly ? 'Reference Index being TESTED (nothing written, use "-e" to update)' : 'Reference Index being Updated'; if ($cli_echo) echo - '*******************************************'.chr(10). - $headerContent.chr(10). - '*******************************************'.chr(10); + '*******************************************'.LF. + $headerContent.LF. + '*******************************************'.LF; // Traverse all tables: foreach ($TCA as $tableName => $cfg) { @@ -1028,7 +1028,7 @@ if ($result['addedNodes'] || $result['deletedNodes']) { $Err = 'Record '.$tableName.':'.$recdat['uid'].' had '.$result['addedNodes'].' added indexes and '.$result['deletedNodes'].' deleted indexes'; $errors[]= $Err; - if ($cli_echo) echo $Err.chr(10); + if ($cli_echo) echo $Err.LF; #$errors[] = t3lib_div::view_array($result); } } @@ -1039,7 +1039,7 @@ if (count($lostIndexes)) { $Err = 'Table '.$tableName.' has '.count($lostIndexes).' lost indexes which are now deleted'; $errors[]= $Err; - if ($cli_echo) echo $Err.chr(10); + if ($cli_echo) echo $Err.LF; if (!$testOnly) $TYPO3_DB->exec_DELETEquery('sys_refindex',$where); } } @@ -1050,14 +1050,14 @@ if (count($lostTables)) { $Err = 'Index table hosted '.count($lostTables).' indexes for non-existing tables, now removed'; $errors[]= $Err; - if ($cli_echo) echo $Err.chr(10); + if ($cli_echo) echo $Err.LF; if (!$testOnly) $TYPO3_DB->exec_DELETEquery('sys_refindex',$where); } - $testedHowMuch = $recCount.' records from '.$tableCount.' tables were checked/updated.'.chr(10); + $testedHowMuch = $recCount.' records from '.$tableCount.' tables were checked/updated.'.LF; - $bodyContent = $testedHowMuch.(count($errors)?implode(chr(10),$errors):'Index Integrity was perfect!'); - if ($cli_echo) echo $testedHowMuch.(count($errors)?'Updates: '.count($errors):'Index Integrity was perfect!').chr(10); + $bodyContent = $testedHowMuch.(count($errors)?implode(LF,$errors):'Index Integrity was perfect!'); + if ($cli_echo) echo $testedHowMuch.(count($errors)?'Updates: '.count($errors):'Index Integrity was perfect!').LF; return array($headerContent,$bodyContent,count($errors)); } Index: t3lib/class.t3lib_htmlmail.php =================================================================== --- t3lib/class.t3lib_htmlmail.php (revision 7304) +++ t3lib/class.t3lib_htmlmail.php (working copy) @@ -269,11 +269,11 @@ // Default line break for Unix systems. - $this->linebreak = chr(10); + $this->linebreak = LF; // Line break for Windows. This is needed because PHP on Windows systems // send mails via SMTP instead of using sendmail, and thus the linebreak needs to be \r\n. if (TYPO3_OS == 'WIN') { - $this->linebreak = chr(13).chr(10); + $this->linebreak = CRLF; } // Sets the Charset @@ -561,13 +561,13 @@ // Generate (plain/HTML) / attachments $this->add_header('Content-Type: multipart/mixed;'); $this->add_header(' boundary="' . $boundary . '"'); - $this->add_message('This is a multi-part message in MIME format.' . "\n"); + $this->add_message('This is a multi-part message in MIME format.' . LF); $this->constructMixed($boundary); } elseif ($this->theParts['html']['content']) { // Generate plain/HTML mail $this->add_header('Content-Type: ' . $this->getHTMLContentType() . ';'); $this->add_header(' boundary="' . $boundary . '"'); - $this->add_message('This is a multi-part message in MIME format.' . "\n"); + $this->add_message('This is a multi-part message in MIME format.' . LF); $this->constructHTML($boundary); } else { // Generate plain only @@ -612,7 +612,7 @@ $this->add_message($this->makeBase64($media['content'])); } } - $this->add_message('--' . $boundary . '--' . "\n"); + $this->add_message('--' . $boundary . '--' . LF); } @@ -662,7 +662,7 @@ $this->add_message($this->html_text_header); $this->add_message(''); $this->add_message($this->getContent('html')); - $this->add_message('--' . $boundary . '--' . "\n"); + $this->add_message('--' . $boundary . '--' . LF); } @@ -686,7 +686,7 @@ } } } - $this->add_message('--' . $boundary . '--' . "\n"); + $this->add_message('--' . $boundary . '--' . LF); } @@ -749,7 +749,7 @@ // Auto response if ($this->auto_respond_msg) { $theParts = explode('/',$this->auto_respond_msg,2); - $theParts[1] = str_replace("/",chr(10),$theParts[1]); + $theParts[1] = str_replace("/",LF,$theParts[1]); if ($returnPathPossible) { $mailWasSent = mail($this->from_email, $theParts[0], @@ -821,7 +821,7 @@ } } - $this->headers .= $header."\n"; + $this->headers .= $header.LF; } @@ -832,7 +832,7 @@ * @return void */ public function add_message($msg) { - $this->message .= $msg."\n"; + $this->message .= $msg.LF; } @@ -1147,7 +1147,7 @@ $pieces = count($textpieces); $textstr = $textpieces[0]; for($i = 1; $i<$pieces; $i++) { - $len = strcspn($textpieces[$i],chr(32).chr(9).chr(13).chr(10)); + $len = strcspn($textpieces[$i],chr(32).TAB.CRLF); if (trim(substr($textstr,-1)) == '' && $len) { $lastChar = substr($textpieces[$i],$len-1,1); if (!preg_match('/[A-Za-z0-9\/#]/',$lastChar)) { @@ -1312,7 +1312,7 @@ while (!feof($fd)) { $line = fgetss($fd, 5000); if (trim($line)) { - $content .= trim($line) . "\n"; + $content .= trim($line) . LF; } } fclose($fd); Index: t3lib/class.t3lib_sqlengine.php =================================================================== --- t3lib/class.t3lib_sqlengine.php (revision 7304) +++ t3lib/class.t3lib_sqlengine.php (working copy) @@ -641,7 +641,7 @@ $itemKeys = array_intersect($itemKeys, $subSelKeys); } } else { - $comp = strtoupper(str_replace(array(' ',"\t","\r","\n"),'',$config['comparator'])); + $comp = strtoupper(str_replace(array(' ',TAB,CR,LF),'',$config['comparator'])); $mod = strtoupper($config['modifier']); switch($comp) { case 'NOTLIKE': Index: t3lib/class.t3lib_cs.php =================================================================== --- t3lib/class.t3lib_cs.php (revision 7304) +++ t3lib/class.t3lib_cs.php (working copy) @@ -987,7 +987,7 @@ $this->parsedCharsets[$charset]=unserialize(t3lib_div::getUrl($cacheFile)); } else { // Parse conversion table into lines: - $lines=t3lib_div::trimExplode(chr(10),t3lib_div::getUrl($charsetConvTableFile),1); + $lines=t3lib_div::trimExplode(LF,t3lib_div::getUrl($charsetConvTableFile),1); // Initialize the internal variable holding the conv. table: $this->parsedCharsets[$charset]=array('local'=>array(),'utf8'=>array()); // traverse the lines: Index: t3lib/class.t3lib_cli.php =================================================================== --- t3lib/class.t3lib_cli.php (revision 7304) +++ t3lib/class.t3lib_cli.php (working copy) @@ -144,7 +144,7 @@ if ($token{0}==='-' && !t3lib_div::testInt($token{1})) { // Options starting with a number is invalid - they could be negative values... ! list($index,$opt) = explode('=',$token,2); if (isset($cli_options[$index])) { - echo 'ERROR: Option '.$index.' was used twice!'.chr(10); + echo 'ERROR: Option '.$index.' was used twice!'.LF; exit; } $cli_options[$index] = array(); @@ -175,7 +175,7 @@ $ii=$i; if ($i>0) { if (!isset($cli_args_copy[$argSplit[0]][$i-1]) && $v{0}!='[') { // Using "[]" around a paramter makes it optional - echo 'ERROR: Option "'.$argSplit[0].'" requires a value ("'.$v.'") on position '.$i.chr(10); + echo 'ERROR: Option "'.$argSplit[0].'" requires a value ("'.$v.'") on position '.$i.LF; exit; } } @@ -183,7 +183,7 @@ $ii++; if (isset($cli_args_copy[$argSplit[0]][$ii-1])) { - echo 'ERROR: Option "'.$argSplit[0].'" does not support a value on position '.$ii.chr(10); + echo 'ERROR: Option "'.$argSplit[0].'" does not support a value on position '.$ii.LF; exit; } @@ -192,7 +192,7 @@ } if (count($cli_args_copy)) { - echo wordwrap('ERROR: Option '.implode(',',array_keys($cli_args_copy)).' was unknown to this script!'.chr(10).'(Options are: '.implode(', ',$allOptions).')'.chr(10)); + echo wordwrap('ERROR: Option '.implode(',',array_keys($cli_args_copy)).' was unknown to this script!'.LF.'(Options are: '.implode(', ',$allOptions).')'.LF); exit; } } @@ -259,7 +259,7 @@ $this->cli_echo($this->cli_indent(str_replace('###OPTIONS###',trim($optStr),$value),4)."\n\n"); break; case 'options': - $this->cli_echo($this->cli_indent($value,4)."\n"); + $this->cli_echo($this->cli_indent($value,4).LF); $maxLen = 0; foreach ($this->cli_options as $v) { @@ -267,9 +267,9 @@ } foreach ($this->cli_options as $v) { - $this->cli_echo($v[0].substr($this->cli_indent(rtrim($v[1].chr(10).$v[2]),$maxLen+4),strlen($v[0]))."\n"); + $this->cli_echo($v[0].substr($this->cli_indent(rtrim($v[1].LF.$v[2]),$maxLen+4),strlen($v[0])).LF); } - $this->cli_echo("\n"); + $this->cli_echo(LF); break; default: $this->cli_echo($this->cli_indent($value,4)."\n\n"); @@ -286,12 +286,12 @@ * @return string Result */ function cli_indent($str,$indent) { - $lines = explode(chr(10),wordwrap($str,75-$indent)); + $lines = explode(LF,wordwrap($str,75-$indent)); $indentStr = str_pad('',$indent,' '); foreach($lines as $k => $v) { $lines[$k] = $indentStr.$lines[$k]; } - return implode(chr(10),$lines); + return implode(LF,$lines); } } Index: t3lib/class.t3lib_fullsearch.php =================================================================== --- t3lib/class.t3lib_fullsearch.php (revision 7304) +++ t3lib/class.t3lib_fullsearch.php (working copy) @@ -143,7 +143,7 @@ $TDparams=' nowrap="nowrap" class="bgColor4"'; $tmpCode=' - +
    doc->formWidth().'>
    '; @@ -441,7 +441,7 @@ } } if (count($rowArr)) { - $out.=''.$this->resultRowTitles($lrow, $TCA[$table], $table).implode(chr(10), $rowArr).'
    '; + $out.=''.$this->resultRowTitles($lrow, $TCA[$table], $table).implode(LF, $rowArr).'
    '; } if (!$out) $out='No rows selected!'; $cPR['header']='Result'; @@ -458,7 +458,7 @@ $rowArr[]=$this->csvValues($row, ',', '"', $TCA[$table], $table); } if (count($rowArr)) { - $out.=''; + $out.=''; if (!$this->noDownloadB) { $out.='
    '; // document.forms[0].target=\'_blank\'; } @@ -468,7 +468,7 @@ $mimeType = 'application/octet-stream'; header('Content-Type: '.$mimeType); header('Content-Disposition: attachment; filename='.$filename); - echo implode(chr(13).chr(10),$rowArr); + echo implode(CRLF,$rowArr); exit; } } @@ -606,7 +606,7 @@ $lrow=$row; } $GLOBALS['TYPO3_DB']->sql_free_result($res); - $out.=''.$this->resultRowTitles($lrow,$conf,$table).implode(chr(10),$rowArr).'
    '; + $out.=''.$this->resultRowTitles($lrow,$conf,$table).implode(LF,$rowArr).'
    '; } $out.='
    '; } @@ -1070,7 +1070,7 @@ // Close header row $tableHeader[] = ''; - return implode($tableHeader, chr(10)); + return implode($tableHeader, LF); } /** Index: t3lib/class.t3lib_loaddbgroup.php =================================================================== --- t3lib/class.t3lib_loaddbgroup.php (revision 7304) +++ t3lib/class.t3lib_loaddbgroup.php (working copy) @@ -298,7 +298,7 @@ if ($this->MM_table_where) { - $additionalWhere.= "\n".str_replace('###THIS_UID###', intval($uid), $this->MM_table_where); + $additionalWhere.= LF.str_replace('###THIS_UID###', intval($uid), $this->MM_table_where); } foreach ($this->MM_match_fields as $field => $value) { $additionalWhere.= ' AND '.$field.'='.$GLOBALS['TYPO3_DB']->fullQuoteStr($value, $tableName); @@ -359,7 +359,7 @@ $additionalWhere = ''; // add WHERE clause if configured if ($this->MM_table_where) { - $additionalWhere.= "\n".str_replace('###THIS_UID###', intval($uid), $this->MM_table_where); + $additionalWhere.= LF.str_replace('###THIS_UID###', intval($uid), $this->MM_table_where); } // Select, update or delete only those relations that match the configured fields foreach ($this->MM_match_fields as $field => $value) { @@ -504,7 +504,7 @@ $additionalWhere = ''; // add WHERE clause if configured if ($this->MM_table_where) { - $additionalWhere.= "\n".str_replace('###THIS_UID###', intval($uid), $this->MM_table_where); + $additionalWhere.= LF.str_replace('###THIS_UID###', intval($uid), $this->MM_table_where); } // Select, update or delete only those relations that match the configured fields foreach ($this->MM_match_fields as $field => $value) { Index: t3lib/class.t3lib_parsehtml.php =================================================================== --- t3lib/class.t3lib_parsehtml.php (revision 7304) +++ t3lib/class.t3lib_parsehtml.php (working copy) @@ -65,7 +65,7 @@ * 1038: function caseShift($str,$flag,$cacheKey='') * 1065: function compileTagAttribs($tagAttrib,$meta=array(), $xhtmlClean=0) * 1093: function get_tag_attributes_classic($tag,$deHSC=0) - * 1106: function indentLines($content, $number=1, $indentChar="\t") + * 1106: function indentLines($content, $number=1, $indentChar=TAB) * 1123: function HTMLparserConfig($TSconfig,$keepTags=array()) * 1247: function XHTML_clean($content) * 1269: function processTag($value,$conf,$endTag,$protected=0) @@ -1233,13 +1233,13 @@ * @param string Indent character/string * @return string Indented code (typ. HTML) */ - function indentLines($content, $number=1, $indentChar="\t") { + function indentLines($content, $number=1, $indentChar=TAB) { $preTab = str_pad('', $number*strlen($indentChar), $indentChar); - $lines = explode(chr(10),str_replace(chr(13),'',$content)); + $lines = explode(LF,str_replace(CR,'',$content)); foreach ($lines as $k => $v) { $lines[$k] = $preTab.$v; } - return implode(chr(10), $lines); + return implode(LF, $lines); } /** Index: t3lib/error/class.t3lib_error_debugexceptionhandler.php =================================================================== --- t3lib/error/class.t3lib_error_debugexceptionhandler.php (revision 7304) +++ t3lib/error/class.t3lib_error_debugexceptionhandler.php (working copy) @@ -130,8 +130,8 @@ $exceptionCodeNumber = ($exception->getCode() > 0) ? '#' . $exception->getCode() . ': ' : ''; $this->writeLogEntries($exception, self::CONTEXT_CLI); - echo "\nUncaught TYPO3 Exception " . $exceptionCodeNumber . $exception->getMessage() . "\n"; - echo "thrown in file " . $filePathAndName . "\n"; + echo "\nUncaught TYPO3 Exception " . $exceptionCodeNumber . $exception->getMessage() . LF; + echo "thrown in file " . $filePathAndName . LF; echo "in line " . $exception->getLine() . "\n\n"; } @@ -158,7 +158,7 @@ $preparedArgument = (strlen($argument) < 100) ? $argument : substr($argument, 0, 50) . '#tripleDot#' . substr($argument, -50); $preparedArgument = htmlspecialchars($preparedArgument); $preparedArgument = str_replace('#tripleDot#', '', $preparedArgument); - $preparedArgument = str_replace(chr(10), '', $preparedArgument); + $preparedArgument = str_replace(LF, '', $preparedArgument); $arguments .= '"' . $preparedArgument . '"'; } elseif (is_numeric($argument)) { $arguments .= '' . (string)$argument . ''; @@ -199,7 +199,7 @@ if ($endLine > $startLine) { $codeSnippet = '
    ' . $filePathAndName . ':
    ';
     					for ($line = $startLine; $line < $endLine; $line++) {
    -						$codeLine = str_replace("\t", ' ', $phpFile[$line-1]);
    +						$codeLine = str_replace(TAB, ' ', $phpFile[$line-1]);
     
     						if ($line === $lineNumber) {
     							$codeSnippet .= '
    ';
    Index: t3lib/class.t3lib_xml.php
    ===================================================================
    --- t3lib/class.t3lib_xml.php	(revision 7304)
    +++ t3lib/class.t3lib_xml.php	(working copy)
    @@ -120,7 +120,7 @@
     	 * @return	string
     	 */
     	function getResult()	{
    -		$content = implode(chr(10),$this->lines);
    +		$content = implode(LF,$this->lines);
     		return $this->output($content);
     	}
     
    @@ -209,7 +209,7 @@
     		if ($b)	$this->XMLIndent++; else $this->XMLIndent--;
     		$this->Icode='';
     		for ($a=0;$a<$this->XMLIndent;$a++)	{
    -			$this->Icode.=chr(9);
    +			$this->Icode.=TAB;
     		}
     		return $this->Icode;
     	}
    @@ -245,7 +245,7 @@
     	/**
     	 * Internal function for adding the actual content of the $row from $table to the internal structure.
     	 * Notice that only fields from $table that are listed in $this->XML_recFields[$table] (set by setRecFields()) will be rendered (and in the order found in that array!)
    -	 * Content from the row will be htmlspecialchar()'ed, UTF-8 encoded and have chr(10) (newlines) exchanged for '' tags. The element name for a value equals the fieldname from the record.
    +	 * Content from the row will be htmlspecialchar()'ed, UTF-8 encoded and have LF (newlines) exchanged for '' tags. The element name for a value equals the fieldname from the record.
     	 *
     	 * @param	string		Table name
     	 * @param	array		Row from table to add.
    @@ -273,13 +273,13 @@
     	}
     
     	/**
    -	 * Substitutes chr(10) characters with a '' tag.
    +	 * Substitutes LF characters with a '' tag.
     	 *
     	 * @param	string		Input value
     	 * @return	string		Processed input value
     	 */
     	function substNewline($string)	{
    -		return str_replace(chr(10),'',$string);
    +		return str_replace(LF,'',$string);
     	}
     
     	/**
    Index: t3lib/class.t3lib_tceforms.php
    ===================================================================
    --- t3lib/class.t3lib_tceforms.php	(revision 7304)
    +++ t3lib/class.t3lib_tceforms.php	(working copy)
    @@ -326,8 +326,8 @@
     
     		$this->RTEenabled = $GLOBALS['BE_USER']->isRTE();
     		if (!$this->RTEenabled)	{
    -			$this->RTEenabled_notReasons = implode(chr(10),$GLOBALS['BE_USER']->RTE_errors);
    -			$this->commentMessages[] = 'RTE NOT ENABLED IN SYSTEM due to:'.chr(10).$this->RTEenabled_notReasons;
    +			$this->RTEenabled_notReasons = implode(LF,$GLOBALS['BE_USER']->RTE_errors);
    +			$this->commentMessages[] = 'RTE NOT ENABLED IN SYSTEM due to:'.LF.$this->RTEenabled_notReasons;
     		}
     
     			// Default color+class scheme
    @@ -1240,7 +1240,7 @@
     		$origRows = $rows = t3lib_div::intInRange($config['rows'] ? $config['rows'] : 5, 1, 20);
     		if (strlen($PA['itemFormElValue']) > $this->charsPerRow*2)	{
     			$cols = $this->maxTextareaWidth;
    -			$rows = t3lib_div::intInRange(round(strlen($PA['itemFormElValue'])/$this->charsPerRow), count(explode(chr(10),$PA['itemFormElValue'])), 20);
    +			$rows = t3lib_div::intInRange(round(strlen($PA['itemFormElValue'])/$this->charsPerRow), count(explode(LF,$PA['itemFormElValue'])), 20);
     			if ($rows<$origRows)	$rows = $origRows;
     		}
     
    @@ -1633,11 +1633,11 @@
     				} else {
     					if (count($optGroupStart)) {
     						if($optGroupOpen) { // Closing last optgroup before next one starts
    -							$opt[]='' . "\n";
    +							$opt[]='' . LF;
     						}
     						$opt[]= '' . "\n";
    +								' class="c-divider">' . LF;
     						$optGroupOpen = true;
     						$c--;
     						$optGroupStart = array();
    @@ -1645,7 +1645,7 @@
     					$opt[]= '' . "\n";
    +							'>'.t3lib_div::deHSCentities(htmlspecialchars($p[0])).'' . LF;
     				}
     			}
     
    @@ -2359,7 +2359,7 @@
     				$origRows = $rows = t3lib_div::intInRange($rows, 1, 20);
     				if (strlen($itemValue)>$this->charsPerRow*2)	{
     					$cols = $this->maxTextareaWidth;
    -					$rows = t3lib_div::intInRange(round(strlen($itemValue)/$this->charsPerRow),count(explode(chr(10),$itemValue)),20);
    +					$rows = t3lib_div::intInRange(round(strlen($itemValue)/$this->charsPerRow),count(explode(LF,$itemValue)),20);
     					if ($rows<$origRows)	$rows=$origRows;
     				}
     			}
    @@ -4613,7 +4613,7 @@
     								// Description texts:
     							if ($this->edit_showFieldHelp)	{
     								$descr = $GLOBALS['LANG']->moduleLabels['labels'][$theMod.'_tablabel'].
    -											chr(10).
    +											LF.
     											$GLOBALS['LANG']->moduleLabels['labels'][$theMod.'_tabdescr'];
     							}
     
    @@ -5446,21 +5446,21 @@
     			// $this->additionalJS_submit:
     		if ($this->additionalJS_submit) {
     			$additionalJS_submit = implode('', $this->additionalJS_submit);
    -			$additionalJS_submit = str_replace("\r", '', $additionalJS_submit);
    -			$additionalJS_submit = str_replace("\n", '', $additionalJS_submit);
    +			$additionalJS_submit = str_replace(CR, '', $additionalJS_submit);
    +			$additionalJS_submit = str_replace(LF, '', $additionalJS_submit);
     			$out .= '
     			TBE_EDITOR.addActionChecks("submit", "'.addslashes($additionalJS_submit).'");
     			';
     		}
     
    -		$out .= chr(10).implode(chr(10),$this->additionalJS_post).chr(10).$this->extJSCODE;
    +		$out .= LF.implode(LF,$this->additionalJS_post).LF.$this->extJSCODE;
     		$out .= '
     			TBE_EDITOR.loginRefreshed();
     		';
     
     			// Regular direct output:
     		if (!$update) {
    -			$spacer = chr(10) . chr(9);
    +			$spacer = LF . TAB;
     			$out  = $spacer . implode($spacer, $jsFile) . t3lib_div::wrapJS($out);
     		}
     
    Index: t3lib/class.t3lib_querygenerator.php
    ===================================================================
    --- t3lib/class.t3lib_querygenerator.php	(revision 7304)
    +++ t3lib/class.t3lib_querygenerator.php	(working copy)
    @@ -1183,13 +1183,13 @@
     		while(list($key,$conf) = each($queryConfig)) {
     			switch($conf['type']) {
     				case 'newlevel':
    -					$qs.=chr(10).$pad.trim($conf['operator']).' ('.$this->getQuery($queryConfig[$key]['nl'],$pad.'   ').chr(10).$pad.')';
    +					$qs.=LF.$pad.trim($conf['operator']).' ('.$this->getQuery($queryConfig[$key]['nl'],$pad.'   ').LF.$pad.')';
     				break;
     				case 'userdef':
    -					$qs.=chr(10).$pad.getUserDefQuery($conf,$first);
    +					$qs.=LF.$pad.getUserDefQuery($conf,$first);
     				break;
     				default:
    -					$qs.=chr(10).$pad.$this->getQuerySingle($conf,$first);
    +					$qs.=LF.$pad.$this->getQuerySingle($conf,$first);
     				break;
     			}
     			$first=0;
    Index: t3lib/class.t3lib_install.php
    ===================================================================
    --- t3lib/class.t3lib_install.php	(revision 7304)
    +++ t3lib/class.t3lib_install.php	(working copy)
    @@ -216,7 +216,7 @@
     		}
     
     				// Splitting localconf.php file into lines:
    -		$lines = explode(chr(10),str_replace(chr(13),'',trim(t3lib_div::getUrl($writeToLocalconf_dat['file']))));
    +		$lines = explode(LF,str_replace(CR,'',trim(t3lib_div::getUrl($writeToLocalconf_dat['file']))));
     		$writeToLocalconf_dat['endLine'] = array_pop($lines);	// Getting "? >" ending.
     
     			// Checking if "updated" line was set by this tool - if so remove old line.
    @@ -235,10 +235,10 @@
     
     			if ($this->setLocalconf)	{
     				$success = FALSE;
    -				if (!t3lib_div::writeFile($writeToLocalconf_dat['tmpfile'],implode(chr(10),$inlines)))	{
    +				if (!t3lib_div::writeFile($writeToLocalconf_dat['tmpfile'],implode(LF,$inlines)))	{
     					$msg = 'typo3conf/localconf.php'.$tmpExt.' could not be written - maybe a write access problem?';
     				}
    -				elseif (strcmp(t3lib_div::getUrl($writeToLocalconf_dat['tmpfile']), implode(chr(10),$inlines)))	{
    +				elseif (strcmp(t3lib_div::getUrl($writeToLocalconf_dat['tmpfile']), implode(LF,$inlines)))	{
     					@unlink($writeToLocalconf_dat['tmpfile']);
     					$msg = 'typo3conf/localconf.php'.$tmpExt.' was NOT written properly (written content didn\'t match file content) - maybe a disk space problem?';
     				}
    @@ -274,7 +274,7 @@
     	 * @see setValueInLocalconfFile()
     	 */
     	function checkForBadString($string)	{
    -		return preg_match('/['.chr(10).chr(13).']/',$string) ? FALSE : TRUE;
    +		return preg_match('/['.LF.CR.']/',$string) ? FALSE : TRUE;
     	}
     
     	/**
    @@ -285,9 +285,9 @@
     	 * @see setValueInLocalconfFile()
     	 */
     	function slashValueForSingleDashes($value)	{
    -		$value = str_replace("'.chr(10).'", '###INSTALL_TOOL_LINEBREAK###', $value);
    +		$value = str_replace("'.LF.'", '###INSTALL_TOOL_LINEBREAK###', $value);
     		$value = str_replace("'","\'",str_replace('\\','\\\\',$value));
    -		$value = str_replace('###INSTALL_TOOL_LINEBREAK###', "'.chr(10).'", $value);
    +		$value = str_replace('###INSTALL_TOOL_LINEBREAK###', "'.LF.'", $value);
     
     		return $value;
     	}
    @@ -314,7 +314,7 @@
     	 * @return	array		Array with information about table.
     	 */
     	function getFieldDefinitions_fileContent($fileContent)	{
    -		$lines = t3lib_div::trimExplode(chr(10), $fileContent, 1);
    +		$lines = t3lib_div::trimExplode(LF, $fileContent, 1);
     		$table = '';
     		$total = array();
     
    @@ -812,7 +812,7 @@
     	 * @return	array		Array of SQL statements
     	 */
     	function getStatementArray($sqlcode,$removeNonSQL=0,$query_regex='')	{
    -		$sqlcodeArr = explode(chr(10), $sqlcode);
    +		$sqlcodeArr = explode(LF, $sqlcode);
     
     			// Based on the assumption that the sql-dump has
     		$statementArray = array();
    @@ -839,7 +839,7 @@
     				$statementArrayPointer++;
     
     			} elseif ($is_set) {
    -				$statementArray[$statementArrayPointer].= chr(10);
    +				$statementArray[$statementArrayPointer].= LF;
     			}
     		}
     
    @@ -865,13 +865,13 @@
     					if (TYPO3_OS == 'WIN') {
     						$table = strtolower($table);
     					}
    -					$sqlLines = explode(chr(10), $lineContent);
    +					$sqlLines = explode(LF, $lineContent);
     					foreach ($sqlLines as $k=>$v) {
     						if (stristr($v,'auto_increment')) {
     							$sqlLines[$k] = preg_replace('/ default \'0\'/i', '', $v);
     						}
     					}
    -					$lineContent = implode(chr(10), $sqlLines);
    +					$lineContent = implode(LF, $sqlLines);
     					$crTables[$table] = $lineContent;
     				}
     			} elseif ($insertCountFlag && preg_match('/^insert[[:space:]]*into[[:space:]]*[`]?([[:alnum:]_]*)[`]?/i',substr($lineContent,0,100),$reg)) {
    Index: t3lib/class.t3lib_tsparser.php
    ===================================================================
    --- t3lib/class.t3lib_tsparser.php	(revision 7304)
    +++ t3lib/class.t3lib_tsparser.php	(working copy)
    @@ -82,7 +82,7 @@
     
     		// Internal
     	var $setup = Array();			// TypoScript hierarchy being build during parsing.
    -	var $raw; 						// raw data, the input string exploded by chr(10)
    +	var $raw; 						// raw data, the input string exploded by LF
     	var $rawP; 						// pointer to entry in raw data array
     	var $lastComment='';			// Holding the value of the last comment
     	var $commentSet=0;				// Internally set, used as internal flag to create a multi-line comment (one of those like /*... */)
    @@ -131,7 +131,7 @@
     	 * @return	void
     	 */
     	function parse($string,$matchObj='')	{
    -		$this->raw = explode(chr(10),$string);
    +		$this->raw = explode(LF,$string);
     		$this->rawP = 0;
     		$pre = '[GLOBAL]';
     		while($pre)	{
    @@ -206,7 +206,7 @@
     					if (substr($line,0,1)==')')	{	// Multiline ends...
     						if ($this->syntaxHighLight)	$this->regHighLight("operator",$lineP,strlen($line)-1);
     						$this->multiLineEnabled=0;	// Disable multiline
    -						$theValue = implode($this->multiLineValue,chr(10));
    +						$theValue = implode($this->multiLineValue,LF);
     						if (strstr($this->multiLineObject,'.'))	{
     							$this->setVal($this->multiLineObject,$setup,array($theValue));	// Set the value deeper.
     						} else {
    @@ -258,7 +258,7 @@
     
     									$tsFuncArg = str_replace(
     										array('\\\\', '\n','\t'),
    -										array('\\', chr(10),chr(9)),
    +										array('\\', LF,TAB),
     										$tsFuncArg
     									);
     
    @@ -371,7 +371,7 @@
     						if ($this->syntaxHighLight)	$this->regHighLight("comment",	$lineP);
     
     							// Comment. The comments are concatenated in this temporary string:
    -						if ($this->regComments) $this->lastComment.= trim($line).chr(10);
    +						if ($this->regComments) $this->lastComment.= trim($line).LF;
     					}
     				}
     			}
    @@ -518,7 +518,7 @@
     		$splitStr=' $v) {
     				if (!$c)	{	 // first goes through
     					$newString.=$v;
    @@ -526,7 +526,7 @@
     					$subparts=explode('>',$v,2);
     					if (preg_match('/^\s*\r?\n/',$subparts[1]))	{	// There must be a line-break char after
     							// SO, the include was positively recognized:
    -						$newString.='### '.$splitStr.$subparts[0].'> BEGIN:'.chr(10);
    +						$newString.='### '.$splitStr.$subparts[0].'> BEGIN:'.LF;
     						$params = t3lib_div::get_tag_attributes($subparts[0]);
     						if ($params['source'])	{
     							$sourceParts = explode(':',$params['source'],2);
    @@ -544,13 +544,13 @@
     												$includedFiles = array_merge($includedFiles, $included_text['files']);
     												$included_text = $included_text['typoscript'];
     											}
    -											$newString.= $included_text.chr(10);
    +											$newString.= $included_text.LF;
     										}
     									}
     								break;
     							}
     						}
    -						$newString.='### '.$splitStr.$subparts[0].'> END:'.chr(10);
    +						$newString.='### '.$splitStr.$subparts[0].'> END:'.LF;
     						$newString.=$subparts[1];
     					} else $newString.=$splitStr.$v;
     				} else $newString.=$splitStr.$v;
    @@ -620,7 +620,7 @@
     		$this->syntaxHighLight=1;
     		$this->highLightData=array();
     		$this->error=array();
    -		$string = str_replace(chr(13),'',$string);		// This is done in order to prevent empty .. sections around chr(13) content. Should not do anything but help lessen the amount of HTML code.
    +		$string = str_replace(CR,'',$string);		// This is done in order to prevent empty .. sections around CR content. Should not do anything but help lessen the amount of HTML code.
     
     		$this->parse($string);
     
    @@ -699,7 +699,7 @@
     			$lines[] = $lineC;
     		}
     
    -		return '
    '.implode(chr(10),$lines).'
    '; + return '
    '.implode(LF,$lines).'
    '; } } Index: t3lib/class.t3lib_sqlparser.php =================================================================== --- t3lib/class.t3lib_sqlparser.php (revision 7304) +++ t3lib/class.t3lib_sqlparser.php (working copy) @@ -135,7 +135,7 @@ // Finding starting keyword of string: $_parseString = $parseString; // Protecting original string... $keyword = $this->nextPart($_parseString, '^(SELECT|UPDATE|INSERT[[:space:]]+INTO|DELETE[[:space:]]+FROM|EXPLAIN|DROP[[:space:]]+TABLE|CREATE[[:space:]]+TABLE|CREATE[[:space:]]+DATABASE|ALTER[[:space:]]+TABLE|TRUNCATE[[:space:]]+TABLE)[[:space:]]+'); - $keyword = strtoupper(str_replace(array(' ',"\t","\r","\n"),'',$keyword)); + $keyword = strtoupper(str_replace(array(' ',TAB,CR,LF),'',$keyword)); switch($keyword) { case 'SELECT': @@ -481,7 +481,7 @@ // While the parseString is not yet empty: while(strlen($parseString)>0) { if ($key = $this->nextPart($parseString, '^(KEY|PRIMARY KEY|UNIQUE KEY|UNIQUE)([[:space:]]+|\()')) { // Getting key - $key = strtoupper(str_replace(array(' ',"\t","\r","\n"),'',$key)); + $key = strtoupper(str_replace(array(' ',TAB,CR,LF),'',$key)); switch($key) { case 'PRIMARYKEY': @@ -557,7 +557,7 @@ if ($result['TABLE']) { if ($result['action'] = $this->nextPart($parseString, '^(CHANGE|DROP[[:space:]]+KEY|DROP[[:space:]]+PRIMARY[[:space:]]+KEY|ADD[[:space:]]+KEY|ADD[[:space:]]+PRIMARY[[:space:]]+KEY|DROP|ADD|RENAME)([[:space:]]+|\()')) { - $actionKey = strtoupper(str_replace(array(' ',"\t","\r","\n"),'',$result['action'])); + $actionKey = strtoupper(str_replace(array(' ',TAB,CR,LF),'',$result['action'])); // Getting field: if (t3lib_div::inList('ADDPRIMARYKEY,DROPPRIMARYKEY',$actionKey) || $fieldKey = $this->nextPart($parseString, '^([[:alnum:]_]+)[[:space:]]+')) { @@ -832,7 +832,7 @@ // Looking for stop-keywords: if ($stopRegex && $this->lastStopKeyWord = $this->nextPart($parseString, $stopRegex)) { - $this->lastStopKeyWord = strtoupper(str_replace(array(' ',"\t","\r","\n"),'',$this->lastStopKeyWord)); + $this->lastStopKeyWord = strtoupper(str_replace(array(' ',TAB,CR,LF),'',$this->lastStopKeyWord)); return $stack; } @@ -917,7 +917,7 @@ if ($stack[$pnt]['table'] = $this->nextPart($parseString,'^([[:alnum:]_]+)(,|[[:space:]]+)')) { // Looking for stop-keywords before fetching potential table alias: if ($stopRegex && ($this->lastStopKeyWord = $this->nextPart($parseString, $stopRegex))) { - $this->lastStopKeyWord = strtoupper(str_replace(array(' ',"\t","\r","\n"), '', $this->lastStopKeyWord)); + $this->lastStopKeyWord = strtoupper(str_replace(array(' ',TAB,CR,LF), '', $this->lastStopKeyWord)); return $stack; } if (!preg_match('/^(LEFT|RIGHT|JOIN|INNER)[[:space:]]+/i', $parseString)) { @@ -969,7 +969,7 @@ // Looking for stop-keywords: if ($stopRegex && $this->lastStopKeyWord = $this->nextPart($parseString, $stopRegex)) { - $this->lastStopKeyWord = strtoupper(str_replace(array(' ',"\t","\r","\n"), '', $this->lastStopKeyWord)); + $this->lastStopKeyWord = strtoupper(str_replace(array(' ',TAB,CR,LF), '', $this->lastStopKeyWord)); return $stack; } @@ -1230,7 +1230,7 @@ // Looking for stop-keywords: if ($stopRegex && $this->lastStopKeyWord = $this->nextPart($parseString, $stopRegex)) { - $this->lastStopKeyWord = strtoupper(str_replace(array(' ',"\t","\r","\n"), '', $this->lastStopKeyWord)); + $this->lastStopKeyWord = strtoupper(str_replace(array(' ',TAB,CR,LF), '', $this->lastStopKeyWord)); return $stack[0]; } else { return $this->parseError('No operator, but parsing not finished in parseWhereClause().', $parseString); @@ -1278,7 +1278,7 @@ // Looking for keywords while($keyword = $this->nextPart($parseString,'^(DEFAULT|NOT[[:space:]]+NULL|AUTO_INCREMENT|UNSIGNED)([[:space:]]+|,|\))')) { - $keywordCmp = strtoupper(str_replace(array(' ',"\t","\r","\n"),'',$keyword)); + $keywordCmp = strtoupper(str_replace(array(' ',TAB,CR,LF),'',$keyword)); $result['featureIndex'][$keywordCmp]['keyword'] = $keyword; @@ -1339,7 +1339,7 @@ protected function getValue(&$parseString, $comparator = '', $mode = '') { $value = ''; - if (t3lib_div::inList('NOTIN,IN,_LIST',strtoupper(str_replace(array(' ',"\n","\r","\t"),'',$comparator)))) { // List of values: + if (t3lib_div::inList('NOTIN,IN,_LIST',strtoupper(str_replace(array(' ',LF,CR,TAB),'',$comparator)))) { // List of values: if ($this->nextPart($parseString,'^([(])')) { $listValues = array(); $comma=','; @@ -1694,7 +1694,7 @@ $query = 'ALTER TABLE '.$components['TABLE'].' '.$components['action'].' '.($components['FIELD']?$components['FIELD']:$components['KEY']); // Based on action, add the final part: - switch(strtoupper(str_replace(array(' ',"\t","\r","\n"),'',$components['action']))) { + switch(strtoupper(str_replace(array(' ',TAB,CR,LF),'',$components['action']))) { case 'ADD': $query.=' '.$this->compileFieldCfg($components['definition']); break; @@ -1929,7 +1929,7 @@ $output .= ' ' . $v['comparator']; // Detecting value type; list or plain: - if (t3lib_div::inList('NOTIN,IN', strtoupper(str_replace(array(' ', "\t", "\r", "\n"), '', $v['comparator'])))) { + if (t3lib_div::inList('NOTIN,IN', strtoupper(str_replace(array(' ', TAB, CR, LF), '', $v['comparator'])))) { if (isset($v['subquery'])) { $output .= ' (' . $this->compileSELECT($v['subquery']) . ')'; } else { @@ -2062,10 +2062,10 @@ # $str1 = stripslashes($str1); # $str2 = stripslashes($str2); - if (strcmp(str_replace(array(' ',"\t","\r","\n"),'',$this->trimSQL($str1)),str_replace(array(' ',"\t","\r","\n"),'',$this->trimSQL($str2)))) { + if (strcmp(str_replace(array(' ',TAB,CR,LF),'',$this->trimSQL($str1)),str_replace(array(' ',TAB,CR,LF),'',$this->trimSQL($str2)))) { return array( - str_replace(array(' ',"\t","\r","\n"),' ',$str), - str_replace(array(' ',"\t","\r","\n"),' ',$newStr), + str_replace(array(' ',TAB,CR,LF),' ',$str), + str_replace(array(' ',TAB,CR,LF),' ',$newStr), ); } } Index: t3lib/class.t3lib_db.php =================================================================== --- t3lib/class.t3lib_db.php (revision 7304) +++ t3lib/class.t3lib_db.php (working copy) @@ -1114,7 +1114,7 @@ 4 ); } else { - $setDBinit = t3lib_div::trimExplode(chr(10), $GLOBALS['TYPO3_CONF_VARS']['SYS']['setDBinit'], TRUE); + $setDBinit = t3lib_div::trimExplode(LF, $GLOBALS['TYPO3_CONF_VARS']['SYS']['setDBinit'], TRUE); foreach ($setDBinit as $v) { if (mysql_query($v, $this->link) === FALSE) { t3lib_div::sysLog('Could not initialize DB connection with query "' . $v . Index: t3lib/class.t3lib_tsstyleconfig.php =================================================================== --- t3lib/class.t3lib_tsstyleconfig.php (revision 7304) +++ t3lib/class.t3lib_tsstyleconfig.php (working copy) @@ -208,7 +208,7 @@ */ function ext_mergeIncomingWithExisting($arr) { $parseObj = t3lib_div::makeInstance("t3lib_TSparser"); - $parseObj->parse(implode(chr(10),$this->ext_incomingValues)); + $parseObj->parse(implode(LF,$this->ext_incomingValues)); $arr2 = $parseObj->setup; return t3lib_div::array_merge_recursive_overrule($arr,$arr2); } Index: t3lib/class.t3lib_tsparser_ext.php =================================================================== --- t3lib/class.t3lib_tsparser_ext.php (revision 7304) +++ t3lib/class.t3lib_tsparser_ext.php (working copy) @@ -466,7 +466,7 @@ if (!is_array($this->lnToScript)) { $this->lnToScript = array(); $c=1; - $c+=substr_count($GLOBALS['TYPO3_CONF_VARS']['FE']['defaultTypoScript_setup'],chr(10))+2; + $c+=substr_count($GLOBALS['TYPO3_CONF_VARS']['FE']['defaultTypoScript_setup'],LF)+2; $this->lnToScript[$c] = '[Default]'; foreach($this->hierarchyInfoToRoot as $info) { @@ -681,11 +681,11 @@ $all=''; reset($config); while (list(,$str)=each($config)) { - $all .= chr(10) .'[GLOBAL]' . chr(10) . $str; + $all .= LF .'[GLOBAL]' . LF . $str; } if ($syntaxHL) { - $all = preg_replace('/^[^'.chr(10).']*./','',$all); + $all = preg_replace('/^[^'.LF.']*./','',$all); $all = chop($all); $tsparser = t3lib_div::makeInstance('t3lib_TSparser'); $tsparser->lineNumberOffset=$this->ext_lineNumberOffset+1; @@ -738,9 +738,9 @@ * @return [type] ... */ function ext_formatTS($input, $ln, $comments=1, $crop=0) { - $input = preg_replace('/^[^'.chr(10).']*./','',$input); + $input = preg_replace('/^[^'.LF.']*./','',$input); $input = chop($input); - $cArr = explode(chr(10),$input); + $cArr = explode(LF,$input); reset($cArr); $n = ceil(log10(count($cArr)+$this->ext_lineNumberOffset)); @@ -823,7 +823,7 @@ while(list($const,$value)=each($this->flatSetup)) { if (substr($const,-2)!='..' && isset($this->flatSetup[$const.'..'])) { $comment = trim($this->flatSetup[$const.'..']); - $c_arr = explode(chr(10),$comment); + $c_arr = explode(LF,$comment); while(list($k,$v)=each($c_arr)) { $line=trim(preg_replace('/^[#\/]*/','',$v)); if ($line) { @@ -1428,7 +1428,7 @@ */ function ext_regObjectPositions($constants) { // This runs through the lines of the constants-field of the active template and registers the constants-names and linepositions in an array, $this->objReg - $this->raw = explode(chr(10),$constants); + $this->raw = explode(LF,$constants); $this->rawP=0; $this->objReg=array(); // resetting the objReg if the divider is found!! @@ -1575,7 +1575,7 @@ while(list($key,$var)=each($data)) { if (isset($theConstants[$key])) { if ($this->ext_dontCheckIssetValues || isset($check[$key])) { // If checkbox is set, update the value - list($var) = explode(chr(10),$var); // exploding with linebreak, just to make sure that no multiline input is given! + list($var) = explode(LF,$var); // exploding with linebreak, just to make sure that no multiline input is given! $typeDat=$this->ext_getTypeData($theConstants[$key]['type']); switch($typeDat['type']) { case 'int': Index: t3lib/class.t3lib_beuserauth.php =================================================================== --- t3lib/class.t3lib_beuserauth.php (revision 7304) +++ t3lib/class.t3lib_beuserauth.php (working copy) @@ -239,10 +239,10 @@ if ($this->user['uid']) { if (!$this->isAdmin()) { return TRUE; - } else die('ERROR: CLI backend user "'.$userName.'" was ADMIN which is not allowed!'.chr(10).chr(10)); - } else die('ERROR: No backend user named "'.$userName.'" was found! [Database: '.TYPO3_db.']'.chr(10).chr(10)); - } else die('ERROR: Module name, "'.$GLOBALS['MCONF']['name'].'", was not prefixed with "_CLI_"'.chr(10).chr(10)); - } else die('ERROR: Another user was already loaded which is impossible in CLI mode!'.chr(10).chr(10)); + } else die('ERROR: CLI backend user "'.$userName.'" was ADMIN which is not allowed!'.LF.LF); + } else die('ERROR: No backend user named "'.$userName.'" was found! [Database: '.TYPO3_db.']'.LF.LF); + } else die('ERROR: Module name, "'.$GLOBALS['MCONF']['name'].'", was not prefixed with "_CLI_"'.LF.LF); + } else die('ERROR: Another user was already loaded which is impossible in CLI mode!'.LF.LF); } } Index: t3lib/class.t3lib_tcemain.php =================================================================== --- t3lib/class.t3lib_tcemain.php (revision 7304) +++ t3lib/class.t3lib_tcemain.php (working copy) @@ -1187,7 +1187,7 @@ $eFileMarker = $eFile['markerField']&&trim($mixedRec[$eFile['markerField']]) ? trim($mixedRec[$eFile['markerField']]) : '###TYPO3_STATICFILE_EDIT###'; $insertContent = str_replace($eFileMarker,'',$mixedRec[$eFile['contentField']]); // must replace the marker if present in content! - $SW_fileNewContent = $parseHTML->substituteSubpart($SW_fileContent, $eFileMarker, chr(10).$insertContent.chr(10), 1, 1); + $SW_fileNewContent = $parseHTML->substituteSubpart($SW_fileContent, $eFileMarker, LF.$insertContent.LF, 1, 1); t3lib_div::writeFile($eFile['editFile'],$SW_fileNewContent); // Write status: @@ -4330,7 +4330,7 @@ foreach($files as $dat) { if (@is_file($dat['ID_absFile'])) { unlink ($dat['ID_absFile']); -#echo 'DELETE FlexFormFile:'.$dat['ID_absFile'].chr(10); +#echo 'DELETE FlexFormFile:'.$dat['ID_absFile'].LF; } else { $this->log($table,0,3,0,100,"Delete: Referenced file '".$dat['ID_absFile']."' that was supposed to be deleted together with it's record didn't exist"); } Index: t3lib/class.t3lib_parsehtml_proc.php =================================================================== --- t3lib/class.t3lib_parsehtml_proc.php (revision 7304) +++ t3lib/class.t3lib_parsehtml_proc.php (working copy) @@ -275,7 +275,7 @@ // Line breaks of content is unified into char-10 only (removing char 13) if (!$this->procOptions['disableUnifyLineBreaks']) { - $value = str_replace(chr(13).chr(10),chr(10),$value); + $value = str_replace(CRLF,LF,$value); } // In an entry-cleaner was configured, pass value through the HTMLcleaner with that: @@ -309,7 +309,7 @@ break; case 'ts_transform': case 'css_transform': - $value = str_replace(chr(13),'',$value); // Has a very disturbing effect, so just remove all '13' - depend on '10' + $value = str_replace(CR,'',$value); // Has a very disturbing effect, so just remove all '13' - depend on '10' $this->allowedClasses = t3lib_div::trimExplode(',', $this->procOptions['allowedClasses'], 1); $value = $this->TS_transform_db($value,$cmd=='css_transform'); break; @@ -344,7 +344,7 @@ break; case 'ts_transform': case 'css_transform': - $value = str_replace(chr(13),'',$value); // Has a very disturbing effect, so just remove all '13' - depend on '10' + $value = str_replace(CR,'',$value); // Has a very disturbing effect, so just remove all '13' - depend on '10' $value = $this->TS_transform_rte($value,$cmd=='css_transform'); break; default: @@ -361,8 +361,8 @@ // Final clean up of linebreaks: if (!$this->procOptions['disableUnifyLineBreaks']) { - $value = str_replace(chr(13).chr(10),chr(10),$value); // Make sure no \r\n sequences has entered in the meantime... - $value = str_replace(chr(10),chr(13).chr(10),$value); // ... and then change all \n into \r\n + $value = str_replace(CRLF,LF,$value); // Make sure no \r\n sequences has entered in the meantime... + $value = str_replace(LF,CRLF,$value); // ... and then change all \n into \r\n } // Return value: @@ -826,7 +826,7 @@ // Traverse the blocks foreach($blockSplit as $k => $v) { $cc++; - $lastBR = $cc==$aC ? '' : chr(10); + $lastBR = $cc==$aC ? '' : LF; if ($k%2) { // Inside block: @@ -847,23 +847,23 @@ if (!isset($this->procOptions['typolist']) || $this->procOptions['typolist']) { $parts = $this->getAllParts($this->splitIntoBlock('LI',$this->removeFirstAndLastTag($blockSplit[$k])),1,0); while(list($k2)=each($parts)) { - $parts[$k2]=preg_replace('/['.preg_quote(chr(10).chr(13)).']+/','',$parts[$k2]); // remove all linesbreaks! + $parts[$k2]=preg_replace('/['.preg_quote(LF.CR).']+/','',$parts[$k2]); // remove all linesbreaks! $parts[$k2]=$this->defaultTStagMapping($parts[$k2],'db'); $parts[$k2]=$this->cleanFontTags($parts[$k2],0,0,0); $parts[$k2] = $this->HTMLcleaner_db($parts[$k2],strtolower($this->procOptions['allowTagsInTypolists']?$this->procOptions['allowTagsInTypolists']:'br,font,b,i,u,a,img,span,strong,em')); } if ($tagName=='ol') { $params=' type="1"'; } else { $params=''; } - $blockSplit[$k]=''.chr(10).implode(chr(10),$parts).chr(10).''.$lastBR; + $blockSplit[$k]=''.LF.implode(LF,$parts).LF.''.$lastBR; } } else { - $blockSplit[$k]=preg_replace('/['.preg_quote(chr(10).chr(13)).']+/',' ',$this->transformStyledATags($blockSplit[$k])).$lastBR; + $blockSplit[$k]=preg_replace('/['.preg_quote(LF.CR).']+/',' ',$this->transformStyledATags($blockSplit[$k])).$lastBR; } break; case 'table': // Tables are NOT allowed in any form (unless preserveTables is set or CSS is the mode) if (!$this->procOptions['preserveTables'] && !$css) { $blockSplit[$k]=$this->TS_transform_db($this->removeTables($blockSplit[$k])); } else { - $blockSplit[$k]=preg_replace('/['.preg_quote(chr(10).chr(13)).']+/',' ',$this->transformStyledATags($blockSplit[$k])).$lastBR; + $blockSplit[$k]=preg_replace('/['.preg_quote(LF.CR).']+/',' ',$this->transformStyledATags($blockSplit[$k])).$lastBR; } break; case 'h1': @@ -898,17 +898,17 @@ } } else { // Eliminate true linebreaks inside Hx tags - $blockSplit[$k]=preg_replace('/['.preg_quote(chr(10).chr(13)).']+/',' ',$this->transformStyledATags($blockSplit[$k])).$lastBR; + $blockSplit[$k]=preg_replace('/['.preg_quote(LF.CR).']+/',' ',$this->transformStyledATags($blockSplit[$k])).$lastBR; } break; default: // Eliminate true linebreaks inside other headlist tags and after hr tag - $blockSplit[$k]=preg_replace('/['.preg_quote(chr(10).chr(13)).']+/',' ',$this->transformStyledATags($blockSplit[$k])).$lastBR; + $blockSplit[$k]=preg_replace('/['.preg_quote(LF.CR).']+/',' ',$this->transformStyledATags($blockSplit[$k])).$lastBR; break; } } else { // NON-block: if (strcmp(trim($blockSplit[$k]),'')) { - $blockSplit[$k]=$this->divideIntoLines(preg_replace('/['.preg_quote(chr(10).chr(13)).']+/',' ',$blockSplit[$k])).$lastBR; + $blockSplit[$k]=$this->divideIntoLines(preg_replace('/['.preg_quote(LF.CR).']+/',' ',$blockSplit[$k])).$lastBR; $blockSplit[$k]=$this->transformStyledATags($blockSplit[$k]); } else unset($blockSplit[$k]); } @@ -976,12 +976,12 @@ case 'typolist': // Transform typolist blocks into OL/UL lists. Type 1 is expected to be numerical block if (!isset($this->procOptions['typolist']) || $this->procOptions['typolist']) { $tListContent = $this->removeFirstAndLastTag($blockSplit[$k]); - $tListContent = preg_replace('/^[ ]*'.chr(10).'/','',$tListContent); - $tListContent = preg_replace('/'.chr(10).'[ ]*$/','',$tListContent); - $lines = explode(chr(10),$tListContent); + $tListContent = preg_replace('/^[ ]*'.LF.'/','',$tListContent); + $tListContent = preg_replace('/'.LF.'[ ]*$/','',$tListContent); + $lines = explode(LF,$tListContent); $typ = $attribArray['type']==1 ? 'ol' : 'ul'; - $blockSplit[$k] = '<'.$typ.'>'.chr(10). - '
  • '.implode('
  • '.chr(10).'
  • ',$lines).'
  • '. + $blockSplit[$k] = '<'.$typ.'>'.LF. + '
  • '.implode('
  • '.LF.'
  • ',$lines).'
  • '. ''; } break; @@ -998,12 +998,12 @@ } break; } - $blockSplit[$k+1] = preg_replace('/^[ ]*'.chr(10).'/','',$blockSplit[$k+1]); // Removing linebreak if typohead + $blockSplit[$k+1] = preg_replace('/^[ ]*'.LF.'/','',$blockSplit[$k+1]); // Removing linebreak if typohead } else { // NON-block: $nextFTN = $this->getFirstTagName($blockSplit[$k+1]); - $singleLineBreak = $blockSplit[$k]==chr(10); + $singleLineBreak = $blockSplit[$k]==LF; if (t3lib_div::inList('TABLE,BLOCKQUOTE,TYPOLIST,TYPOHEAD,'.($this->procOptions['preserveDIVSections']?'DIV,':'').$this->blockElementList,$nextFTN)) { // Removing linebreak if typolist/typohead - $blockSplit[$k] = preg_replace('/'.chr(10).'[ ]*$/','',$blockSplit[$k]); + $blockSplit[$k] = preg_replace('/'.LF.'[ ]*$/','',$blockSplit[$k]); } // If $blockSplit[$k] is blank then unset the line. UNLESS the line happend to be a single line break. if (!strcmp($blockSplit[$k],'') && !$singleLineBreak) { @@ -1013,7 +1013,7 @@ } } } - return implode(chr(10),$blockSplit); + return implode(LF,$blockSplit); } /** @@ -1199,7 +1199,7 @@ } /** - * This resolves the $value into parts based on
    -sections and

    -sections and
    -tags. These are returned as lines separated by chr(10). + * This resolves the $value into parts based on

    -sections and

    -sections and
    -tags. These are returned as lines separated by LF. * This point is to resolve the HTML-code returned from RTE into ordinary lines so it's 'human-readable' * The function ->setDivTags does the opposite. * This function processes content to go into the database. @@ -1290,7 +1290,7 @@ } // Remove any line break char (10 or 13) - $subLines[$sk]=preg_replace('/'.chr(10).'|'.chr(13).'/','',$subLines[$sk]); + $subLines[$sk]=preg_replace('/'.LF.'|'.CR.'/','',$subLines[$sk]); // If there are any attributes or if we are supposed to remap the tag, then do so: if (count($newAttribs) && strcmp($remapParagraphTag,'1')) { @@ -1301,7 +1301,7 @@ } } // Add the processed line(s) - $divSplit[$k] = implode(chr(10),$subLines); + $divSplit[$k] = implode(LF,$subLines); // If it turns out the line is just blank (containing a   possibly) then just make it pure blank. // But, prevent filtering of lines that are blank in sense above, but whose tags contain attributes. @@ -1317,7 +1317,7 @@ } // Return value: - return $returnArray ? $divSplit : implode(chr(10),$divSplit); + return $returnArray ? $divSplit : implode(LF,$divSplit); } /** @@ -1337,8 +1337,8 @@ $hSC = $this->procOptions['dontHSC_rte'] ? 0 : 1; // Default: re-convert literals to characters (that is < to <) $convNBSP = !$this->procOptions['dontConvAmpInNBSP_rte']?1:0; - // Divide the content into lines, based on chr(10): - $parts = explode(chr(10),$value); + // Divide the content into lines, based on LF: + $parts = explode(LF,$value); foreach($parts as $k => $v) { // Processing of line content: @@ -1360,7 +1360,7 @@ } // Implode result: - return implode(chr(10),$parts); + return implode(LF,$parts); } /** Index: t3lib/class.t3lib_diff.php =================================================================== --- t3lib/class.t3lib_diff.php (revision 7304) +++ t3lib/class.t3lib_diff.php (working copy) @@ -94,7 +94,7 @@ $str1Lines = $this->explodeStringIntoWords($str1); $str2Lines = $this->explodeStringIntoWords($str2); - $diffRes = $this->getDiff(implode(chr(10),$str1Lines).chr(10),implode(chr(10),$str2Lines).chr(10)); + $diffRes = $this->getDiff(implode(LF,$str1Lines).LF,implode(LF,$str2Lines).LF); if (is_array($diffRes)) { reset($diffRes); @@ -143,7 +143,7 @@ } $outString.=$this->addClearBuffer($clearBuffer,1); - $outString = str_replace(' ',chr(10),$outString); + $outString = str_replace(' ',LF,$outString); if (!$this->stripTags) { $outString = $this->tagSpace($outString,1); } @@ -203,7 +203,7 @@ * @access private */ function explodeStringIntoWords($str) { - $strArr = t3lib_div::trimExplode(chr(10),$str); + $strArr = t3lib_div::trimExplode(LF,$str); $outArray=array(); reset($strArr); while(list(,$lineOfWords)=each($strArr)) { Index: t3lib/class.t3lib_flexformtools.php =================================================================== --- t3lib/class.t3lib_flexformtools.php (revision 7304) +++ t3lib/class.t3lib_flexformtools.php (working copy) @@ -464,7 +464,7 @@ $output = t3lib_div::array2xml($array,'',0,'T3FlexForms', $spaceInd, $options); if ($addPrologue) { - $output = 'charSet.'" standalone="yes" ?>'.chr(10).$output; + $output = 'charSet.'" standalone="yes" ?>'.LF.$output; } return $output; Index: t3lib/class.t3lib_superadmin.php =================================================================== --- t3lib/class.t3lib_superadmin.php (revision 7304) +++ t3lib/class.t3lib_superadmin.php (working copy) @@ -848,7 +848,7 @@ // List of those extension keys in a form field: $extensionKeysCollect = array_unique($extensionKeysCollect); asort($extensionKeysCollect); - $out.='

    '; + $out.='
    '; // USER extension (prefixed "user_") $out.='
    @@ -1094,7 +1094,7 @@ // debug($row); } - return '
    '.implode(chr(10),$lines).'
    '; + return '
    '.implode(LF,$lines).'
    '; } /**