Index: t3lib/class.t3lib_tsstyleconfig.php =================================================================== --- t3lib/class.t3lib_tsstyleconfig.php (revision 8742) +++ t3lib/class.t3lib_tsstyleconfig.php (revision ) @@ -1,29 +1,29 @@ tt_track = 0; // Do not log time-performance information + $this->tt_track = 0; // Do not log time-performance information - $this->constants=array($configTemplate,""); + $this->constants = array($configTemplate, ""); - $theConstants = $this->generateConfig_constants(); // The editable constants are returned in an array. + $theConstants = $this->generateConfig_constants(); // The editable constants are returned in an array. - $this->ext_localGfxPrefix=$pathAbs; + $this->ext_localGfxPrefix = $pathAbs; - $this->ext_localWebGfxPrefix=$backPath.$pathRel; + $this->ext_localWebGfxPrefix = $backPath . $pathRel; $this->ext_backPath = $backPath; return $theConstants; @@ -114,23 +104,23 @@ * @param [type] $valueArray: ... * @return [type] ... */ - function ext_setValueArray($theConstants,$valueArray) { + function ext_setValueArray($theConstants, $valueArray) { $temp = $this->flatSetup; - $this->flatSetup = Array(); + $this->flatSetup = array(); - $this->flattenSetup($valueArray,"",""); + $this->flattenSetup($valueArray, "", ""); $this->objReg = $this->ext_realValues = $this->flatSetup; $this->flatSetup = $temp; foreach ($theConstants as $k => $p) { - if (isset($this->objReg[$k])) { + if (isset($this->objReg[$k])) { $theConstants[$k]["value"] = $this->ext_realValues[$k]; } } - $this->categories=array(); // Reset the default pool of categories. + $this->categories = array(); // Reset the default pool of categories. - $this->ext_categorizeEditableConstants($theConstants); // The returned constants are sorted in categories, that goes into the $this->categories array + $this->ext_categorizeEditableConstants($theConstants); // The returned constants are sorted in categories, that goes into the $this->categories array return $theConstants; } @@ -140,7 +130,7 @@ * * @return [type] ... */ - function ext_getCategoriesForModMenu() { + function ext_getCategoriesForModMenu() { return $this->ext_getCategoryLabelArray(); } @@ -150,7 +140,7 @@ * @param [type] $cat: ... * @return [type] ... */ - function ext_makeHelpInformationForCategory($cat) { + function ext_makeHelpInformationForCategory($cat) { return $this->ext_getTSCE_config($cat); } @@ -163,23 +153,23 @@ * @param [type] $addFields: ... * @return [type] ... */ - function ext_getForm($cat,$theConstants,$script="",$addFields="") { + function ext_getForm($cat, $theConstants, $script = "", $addFields = "") { $this->ext_makeHelpInformationForCategory($cat); - $printFields = trim($this->ext_printFields($theConstants,$cat)); + $printFields = trim($this->ext_printFields($theConstants, $cat)); - $content=''; + $content = ''; $content .= t3lib_div::wrapJS(' function uFormUrl(aname) { document.' . $this->ext_CEformName . '.action = "' . t3lib_div::linkThisScript() . '#"+aname; } '); $content .= '
'; - $content.= $addFields; + $content .= $addFields; - $content.= $printFields; + $content .= $printFields; - $content.= ''; + $content .= ''; $example = $this->ext_displayExample(); - $content.= $example?'
'.$example:""; + $content .= $example ? '
' . $example : ""; return $content; } @@ -189,12 +179,12 @@ * * @return [type] ... */ - function ext_displayExample() { + function ext_displayExample() { - global $SOBE,$tmpl; + global $SOBE, $tmpl; - if ($this->helpConfig["imagetag"] || $this->helpConfig["description"] || $this->helpConfig["header"]) { + if ($this->helpConfig["imagetag"] || $this->helpConfig["description"] || $this->helpConfig["header"]) { - $out = '
'.$this->helpConfig["imagetag"].'

'. + $out = '
' . $this->helpConfig["imagetag"] . '

' . - ($this->helpConfig["description"] ? implode(explode("//",$this->helpConfig["description"]),"
")."
" : ""). + ($this->helpConfig["description"] ? implode(explode("//", $this->helpConfig["description"]), "
") . "
" : "") . - ($this->helpConfig["bulletlist"] ? "" : "
"); + ($this->helpConfig["bulletlist"] ? "" : "
"); } return $out; } @@ -205,16 +195,16 @@ * @param [type] $arr: ... * @return [type] ... */ - function ext_mergeIncomingWithExisting($arr) { + function ext_mergeIncomingWithExisting($arr) { $parseObj = t3lib_div::makeInstance("t3lib_TSparser"); - $parseObj->parse(implode(LF,$this->ext_incomingValues)); + $parseObj->parse(implode(LF, $this->ext_incomingValues)); $arr2 = $parseObj->setup; - return t3lib_div::array_merge_recursive_overrule($arr,$arr2); + return t3lib_div::array_merge_recursive_overrule($arr, $arr2); } // extends: - function ext_getKeyImage($key) { + function ext_getKeyImage($key) { - return 'ext_backPath,'gfx/rednumbers/'.$key.'.gif','').' hspace="2" align="top" alt="" />'; + return 'ext_backPath, 'gfx/rednumbers/' . $key . '.gif', '') . ' hspace="2" align="top" alt="" />'; } /** @@ -223,11 +213,11 @@ * @param [type] $imgConf: ... * @return [type] ... */ - function ext_getTSCE_config_image($imgConf) { + function ext_getTSCE_config_image($imgConf) { - $iFile=$this->ext_localGfxPrefix.$imgConf; + $iFile = $this->ext_localGfxPrefix . $imgConf; - $tFile=$this->ext_localWebGfxPrefix.$imgConf; + $tFile = $this->ext_localWebGfxPrefix . $imgConf; - $imageInfo=@getImagesize($iFile); + $imageInfo = @getImagesize($iFile); - return ''; + return ''; } /** @@ -236,16 +226,16 @@ * @param [type] $params: ... * @return [type] ... */ - function ext_fNandV($params) { + function ext_fNandV($params) { - $fN='data['.$params["name"].']'; + $fN = 'data[' . $params["name"] . ']'; - $fV=$params["value"]=isset($this->ext_realValues[$params["name"]]) ? $this->ext_realValues[$params["name"]] : $params["default_value"]; + $fV = $params["value"] = isset($this->ext_realValues[$params["name"]]) ? $this->ext_realValues[$params["name"]] : $params["default_value"]; $reg = array(); - if (preg_match('/^\{[\$][a-zA-Z0-9\.]*\}$/',trim($fV),$reg)) { // Values entered from the constantsedit cannot be constants! + if (preg_match('/^\{[\$][a-zA-Z0-9\.]*\}$/', trim($fV), $reg)) { // Values entered from the constantsedit cannot be constants! - $fV=""; + $fV = ""; } - $fV=htmlspecialchars($fV); + $fV = htmlspecialchars($fV); - return array($fN,$fV,$params); + return array($fN, $fV, $params); } /** @@ -254,9 +244,9 @@ * @param [type] $absPath: ... * @return [type] ... */ - function ext_loadResources($absPath) { + function ext_loadResources($absPath) { $this->ext_readDirResources($GLOBALS["TYPO3_CONF_VARS"]["MODS"]["web_ts"]["onlineResourceDir"]); - if (is_dir($absPath)) { + if (is_dir($absPath)) { $absPath = rtrim($absPath, '/'); $this->readDirectory($absPath); } @@ -270,8 +260,8 @@ * @param [type] $var: ... * @return [type] ... */ - function ext_putValueInConf($key, $var) { + function ext_putValueInConf($key, $var) { - $this->ext_incomingValues[$key]=$key."=".$var; + $this->ext_incomingValues[$key] = $key . "=" . $var; } /** @@ -280,13 +270,13 @@ * @param [type] $key: ... * @return [type] ... */ - function ext_removeValueInConf($key) { + function ext_removeValueInConf($key) { // Nothing... } } -if (defined('TYPO3_MODE') && $TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['t3lib/class.t3lib_tsstyleconfig.php']) { +if (defined('TYPO3_MODE') && $TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['t3lib/class.t3lib_tsstyleconfig.php']) { include_once($TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['t3lib/class.t3lib_tsstyleconfig.php']); } ?> \ No newline at end of file