Commit 5f5e16cc authored by Kasper Skårhøj's avatar Kasper Skårhøj
Browse files

See changelog


git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@460 709f56b5-9817-0410-a4d7-c38de5d9e867
parent e53b7714
2004-09-11 Kasper Skårhøj,,, <kasper@typo3.com>
* Updated changelog for 09/09
* Fixed bug in stdgraphic::fontResize that made it go into eternal loops if the size could not be obtained in the lower end, basically when fontsize reached zero...
* Fixed bug in alt_menu_functions which prevented Condensed Mode from working. But most likely it breaks something else, maybe some options around alternative navigation frame scripts that rene introduced.
* Fixed a bug introduced yesterday where TYPO3 would not work with PHP versions below 4.100.0... :-) - clearly testifying to the fact that I have now run TYPO3 on PHP5 with TemplaVoila et al. for five days without problems.
* Added new option for the dynamic tab menus where you can configure a free initial default tab index and even close all items totally (like toggle mode, but still with only one tab open at a time).
* Increased levels of possible recursive permission setting to 10.
* Web>Page: Introduced localization flags, removed move-up/down/new buttons for languages in default-content-binding mode and made the selection of default elements include the "All" language in default-content-binding mode which will correspond to how sys_language_overlay works in the frontend.
* Introduced baseUrlWrap() function in tslib_fe (TSFE) which can be called for wrapping URLs with absolute baseUrl prefix in case you are using "realurl" of sorts. This is necessary to do for all urls that is handled by JavaScript, like "document.location" or "window.open" cases.
* Fixed the realurl related bug with click-enlarged images that would open a non-existing URL (see "baseUrlWrap()" above). Also wrapped other JavaScript URls like in JSMENU and typolink related JSwindow action.
* Introduced a global setting for GIFBUILDER TEXT objects to configure alternative font files for certain Unicode char ranges. This feature makes it very easy to set up eg. a japanese truetype font for all usages of GIFBUILDER where you still want another specific font used for the latin characters.
* Introduced new HMENU feature: "alwaysActivePIDlist" which can configure certain page id which will always be expanded in menu as if they were "active".
* Fixed problem with empty URLs in menu generation. Empty URLs may occur when a realurl points to the frontpage (which is a blank suffix to the base url). In such cases the URL now becomes the baseUrl of the site (if that is configured!). This should fix it very specifically for all realurl cases.
* Fixed install tools incapability to delete files with certain prefixes in typo3temp/ folder.
2004-09-09 Kasper Skårhøj,,, <kasper@typo3.com>
Sorry for writing these changelog entries with a delay of two days. I write them based on a CVS patch and it took ages to make that from a parking lot in Suresnes, Paris, 4 am in the morning. Its becoming harder to find a stable hotspot in Paris I think... But here we go:
* Changed all HTTP_*_VARS to $_* superglobals. Also raised PHP requirement version to 4.1.0
* Added wrapping functions to array browser class. Also updated the Configuration module to use these features so you can now click a key and get a string served ready to implement in eg. localconf.php
* !!! Removed obsolete function "t3lib_div::setGPvars()"
* Added $MCONF['shy'] feature (requested by Rene Fritz)
* Added longblob in sqlparser
* Added configurable JPG quality setting to stdGraphic class. Use $TYPO4_CONF_VARS[GFX][im_jpg_quality]
* Added stdgraphic::ImageTTFTextWrapper() and stdgraphic::ImageTTFBBoxWrapper functions. Behind these changes a new feature has been implemented which makes it possible to render a single GIFBUILDER TEXT object with more than one font file for various criteria. The most important criteria is that a certain range of unicode chars can be rendered using another truetype font supporting eg. japanese glyphs while you still use another specific font for the design of latin chracters. This feature is known as "splitRendering" in GIFBUILDER TEXT objects.
* Added new swapping mode setting for versioning: swapContent = ALL which is what you use if you want to swap the SUBTREE of a page as well!
* Fixed a bug in transferdata class where too many field values were returned in wrong situations.
* Fixed the timetrack class whitespace issue, removed the DAM module key in stddb/tables.php and removed the temporary class "t3lib_TCEforms_SelectTreeView" made by Rene Fritz.
* Implemented configurable session timeout for backend users.
* Changed the TYPO3 version number variable into a constant available before ext_localconf.php files are included.
* Added "location" bar to the re-login screen. Inspired by Johannes Reichart who once many years ago sent me a mail about how the login screen should be protected against someone designing a similar prompt to trick users into giving them their passwords. I couldn't find a better idea than making the URL visible so people can validate the domain themselves.
* Added localization view mode in Web>List module, allowing to see localization details for records, grouping them by their language and providing a "localization copy" button.
* Updated english labels for backend/CSH according to change suggestions by 3EV from UK. Thanks.
* Added obTS specific hook in tslib_content class. For Dan Frost and his empire...
* Impleemnted third option for stdWrap crop feature (by Peter Klein)
* Fixed typolink that would reject links to virtual files and folders locally, eg. links made by realurl etc. Previously such files HAD to exist, otherwise the link would not be rendered.
* Changed stuff around the pagenotfound handling.
* moved <meta charset...> in frontend output to be the first tag after the <html> tag.
* Fixed old bug in tslib_search which cropped off the last char of a search word.
* Fixed extra_page_cm_options that didn't detect itself properly when making the second menu. So now the elements from that extension will NOT anymore pop up in other second level menus... :-)
2004-09-10 Michael Stucki <mundaun@gmx.ch>
* Replaced t3lib_div::uniqueArray with native PHP function array_unique. The old function will remain for compatibility reasons only. Please do not use it anymore!
......
......@@ -253,6 +253,16 @@ Extensions:
*****************
PHP issues
*****************
Generally: TYPO3 works with PHP5. But...:
- UTF-8 strings to freetype doesn't work! Renders box instead.
- array_merge must always have arrays as arguments. When this problem is found in TYPO3 it is regarded a TYPO3 bug and we fix it.
- Errors regarding treating strings as arrays: Normally, just check if the variable is an array first.
- Details: Non-existing indexes is not a problem if the variable is unset - only if it is another type (eg. string). This means we can normally just check if the first index is an array and it will work: is (is_array($a) && $a[key1][key2][key3]) ...
*****************
NOTES
......
......@@ -132,7 +132,7 @@ class t3lib_DB {
// Debug:
var $debugOutput = TRUE; // Set "TRUE" if you want database errors outputted.
var $debugOutput = FALSE; // Set "TRUE" if you want database errors outputted.
var $debug_lastBuiltQuery = ''; // Internally: Set to last built query (not necessarily executed...)
// Default link identifier:
......
......@@ -292,7 +292,7 @@ class t3lib_pageSelect {
* @param string Overlay mode. If "hideNonTranslated" then records without translation will not be returned un-translated but unset (and return value is false)
* @return mixed Returns the input record, possibly overlaid with a translation. But if $OLmode is "hideNonTranslated" then it will return false if no translation is found.
*/
function getRecordOverlay($table,$row,$sys_language_content,$OLmode) {
function getRecordOverlay($table,$row,$sys_language_content,$OLmode='') {
global $TCA;
if ($row['uid']>0 && $row['pid']>0) {
......@@ -332,7 +332,7 @@ class t3lib_pageSelect {
}
}
}
} elseif ($OLmode=='hideNonTranslated' && $row[$TCA[$table]['ctrl']['languageField']]==0) { // Unset, if non-translated records should be hidden. ONLY done if the source record really is default language and not [All] in which case it is allowed.
} elseif ($OLmode==='hideNonTranslated' && $row[$TCA[$table]['ctrl']['languageField']]==0) { // Unset, if non-translated records should be hidden. ONLY done if the source record really is default language and not [All] in which case it is allowed.
unset($row);
}
......
......@@ -101,6 +101,8 @@ class t3lib_recordList {
var $eCounter=0;
var $HTMLcode=''; // String with accumulated HTML content
var $pageOverlays = array(); // Contains page translation languages
var $languageIconTitles = array(); // Contains sys language icons and titles
......@@ -329,6 +331,82 @@ class t3lib_recordList {
';
}
/**
* Initializes page languages and icons
*
* @return void
*/
function initializeLanguages() {
global $TCA,$LANG;
// Look up page overlays:
$this->pageOverlays = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
'*',
'pages_language_overlay',
'pid='.intval($this->id).
t3lib_BEfunc::deleteClause('pages_language_overlay'),
'',
'',
'',
'sys_language_uid'
);
// icons and language titles:
t3lib_div::loadTCA ('sys_language');
$flagAbsPath = t3lib_div::getFileAbsFileName($TCA['sys_language']['columns']['flag']['config']['fileFolder']);
$flagIconPath = $this->backPath.'../'.substr($flagAbsPath, strlen(PATH_site));
$this->modSharedTSconfig = t3lib_BEfunc::getModTSconfig($this->id, 'mod.SHARED');
$this->languageIconTitles = array();
// Set default:
$this->languageIconTitles[0]=array(
'uid' => 0,
'title' => strlen ($this->modSharedTSconfig['properties']['defaultLanguageFlag']) ? $this->modSharedTSconfig['properties']['defaultLanguageLabel'].' ('.$LANG->getLL('defaultLanguage').')' : $LANG->getLL('defaultLanguage'),
'ISOcode' => 'DEF',
'flagIcon' => strlen($this->modSharedTSconfig['properties']['defaultLanguageFlag']) && @is_file($flagAbsPath.$this->modSharedTSconfig['properties']['defaultLanguageFlag']) ? $flagIconPath.$this->modSharedTSconfig['properties']['defaultLanguageFlag'] : null,
);
// Set "All" language:
$this->languageIconTitles[-1]=array(
'uid' => -1,
'title' => $LANG->getLL ('multipleLanguages'),
'ISOcode' => 'DEF',
'flagIcon' => $flagIconPath.'multi-language.gif',
);
// Find all system languages:
$sys_languages = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
'*',
'sys_language',
''
);
foreach($sys_languages as $row) {
$this->languageIconTitles[$row['uid']] = $row;
if ($row['static_lang_isocode']) {
$staticLangRow = t3lib_BEfunc::getRecord('static_languages',$row['static_lang_isocode'],'lg_iso_2');
if ($staticLangRow['lg_iso_2']) {
$this->languageIconTitles[$row['uid']]['ISOcode'] = $staticLangRow['lg_iso_2'];
}
}
if (strlen ($row['flag'])) {
$this->languageIconTitles[$row['uid']]['flagIcon'] = @is_file($flagAbsPath.$row['flag']) ? $flagIconPath.$row['flag'] : '';
}
}
}
/**
* Return the icon for the language
*
* @param integer Sys language uid
* @return string Language icon
*/
function languageFlag($sys_language_uid) {
return ($this->languageIconTitles[$sys_language_uid]['flagIcon'] ? '<img src="'.$this->languageIconTitles[$sys_language_uid]['flagIcon'].'" class="absmiddle" alt="" />&nbsp;' : '').
htmlspecialchars($this->languageIconTitles[$sys_language_uid]['title']);
}
}
......
......@@ -874,9 +874,7 @@ class t3lib_stdGraphic {
return $conf['fontSize'];
// ################ no calc for spacing yet !!!!!!
} else {
$fontSize = $conf['fontSize'];
do {
$conf['fontSize'] = $fontSize;
// determine bounding box.
$bounds = $this->ImageTTFBBoxWrapper($conf['fontSize'], $conf['angle'], $conf['fontFile'], $this->recodeString($conf['text']), $conf['splitRendering.']);
if ($conf['angle']< 0) {
......@@ -886,12 +884,14 @@ class t3lib_stdGraphic {
} else {
$pixelWidth = abs($bounds[4]-$bounds[6]);
}
// This is a very raw calculation but it makes it in one step
$fontSize=(int)($maxWidth*$fontSize/$pixelWidth);
if ($fontSize >= $conf['fontSize']) {
$fontSize = $conf['fontSize']-1;
// Size is fine, exit:
if ($pixelWidth <= $maxWidth) {
break;
} else {
$conf['fontSize']--;
}
} while ($pixelWidth > $maxWidth);
} while ($conf['fontSize']>1);
}//if spacing
}
return $conf['fontSize'];
......
......@@ -116,7 +116,7 @@ class alt_menu_functions {
while(list($moduleName,$moduleInfo)=each($theModules)) {
$mC++;
$prefix=$this->getNavFramePrefix ($moduleInfo);
$prefix=$this->getNavFramePrefix ($moduleInfo);
if ($prefix) {
$this->fsMod[]='fsMod.recentIds["'.$moduleName.'"]="";';
}
......@@ -155,7 +155,7 @@ class alt_menu_functions {
// Creating the various links:
$label = $LANG->moduleLabels['tabs'][$moduleKey];
if ($link && $prefix) $link=$prefix.'"+top.TS.PATH_typo3_enc+"'.rawurlencode($link);
if ($link && $prefix) $link=$prefix.rawurlencode($link);
if ($link && !$dontLink) {
$label = '<a href="#" onclick="top.goToModule(\''.$moduleName.'\');'.$onBlur.'return false;">'.$label.'</a>'; // && !$link_sub
......@@ -203,8 +203,8 @@ class alt_menu_functions {
}
$link = $subInfo['script'];
$prefix=$this->getNavFramePrefix ($moduleInfo, $subInfo);
$prefix=$this->getNavFramePrefix ($moduleInfo, $subInfo);
$subKey = $moduleName.'_'.$subName.'_tab';
$moduleCSSId = 'ID_'.t3lib_div::md5int($moduleName.'_'.$subName);
......@@ -225,7 +225,7 @@ class alt_menu_functions {
$label_descr = ' title="'.htmlspecialchars($LANG->moduleLabels['labels'][$subKey.'label']).'"';
$flabel = htmlspecialchars($label);
$origLink = $link;
if ($link && $prefix) $link=$prefix.'"+top.TS.PATH_typo3_enc+"'.rawurlencode($link);
if ($link && $prefix) $link=$prefix.rawurlencode($link);
// Setting additional JavaScript if frameset script:
$addJS = '';
......@@ -399,6 +399,8 @@ class alt_menu_functions {
* @return string Result url string
*/
function getNavFramePrefix ($moduleInfo, $subModuleInfo=array()) {
global $BE_USER;
$prefix = '';
$navFrameScriptParam = $subModuleInfo['navFrameScriptParam'] ? $subModuleInfo['navFrameScriptParam'] : $moduleInfo['navFrameScriptParam'];
if ($moduleInfo['navFrameScript']) {
......@@ -413,7 +415,7 @@ class alt_menu_functions {
}
return $prefix;
}
/**
* Returns $Ifilename readable for script in PATH_typo3.
* That means absolute names are just returned while relative names are prepended with $backPath (pointing back to typo3/ dir)
......
......@@ -113,8 +113,6 @@ class recordList extends t3lib_recordList {
var $perms_clause=''; // Page select permissions
var $calcPerms=0; // Some permissions...
var $clickTitleMode = ''; // Mode for what happens when a user clicks the title of a record.
var $pageOverlays = array(); // Contains page translation languages
var $languageIconTitles = array(); // Contains sys language icons and titles
var $modSharedTSconfig = array(); // Shared module configuration, used by localization features
// Internal, dynamic:
......@@ -658,71 +656,6 @@ class recordList extends t3lib_recordList {
$tree->ids[]=$id;
return $tree;
}
/**
* Initializes page languages and icons
*
* @return void
*/
function initializeLanguages() {
global $TCA,$LANG;
// Look up page overlays:
$this->pageOverlays = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
'*',
'pages_language_overlay',
'pid='.intval($this->id).
t3lib_BEfunc::deleteClause('pages_language_overlay'),
'',
'',
'',
'sys_language_uid'
);
// icons and language titles:
t3lib_div::loadTCA ('sys_language');
$flagAbsPath = t3lib_div::getFileAbsFileName($TCA['sys_language']['columns']['flag']['config']['fileFolder']);
$flagIconPath = $this->backPath.'../'.substr($flagAbsPath, strlen(PATH_site));
$this->modSharedTSconfig = t3lib_BEfunc::getModTSconfig($this->id, 'mod.SHARED');
$this->languageIconTitles = array();
// Set default:
$this->languageIconTitles[0]=array(
'uid' => 0,
'title' => strlen ($this->modSharedTSconfig['properties']['defaultLanguageFlag']) ? $this->modSharedTSconfig['properties']['defaultLanguageLabel'].' ('.$LANG->getLL('defaultLanguage').')' : $LANG->getLL('defaultLanguage'),
'ISOcode' => 'DEF',
'flagIcon' => strlen($this->modSharedTSconfig['properties']['defaultLanguageFlag']) && @is_file($flagAbsPath.$this->modSharedTSconfig['properties']['defaultLanguageFlag']) ? $flagIconPath.$this->modSharedTSconfig['properties']['defaultLanguageFlag'] : null,
);
// Set "All" language:
$this->languageIconTitles[-1]=array(
'uid' => -1,
'title' => $LANG->getLL ('multipleLanguages'),
'ISOcode' => 'DEF',
'flagIcon' => $flagIconPath.'multi-language.gif',
);
// Find all system languages:
$sys_languages = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
'*',
'sys_language',
''
);
foreach($sys_languages as $row) {
$this->languageIconTitles[$row['uid']] = $row;
if ($row['static_lang_isocode']) {
$staticLangRow = t3lib_BEfunc::getRecord('static_languages',$row['static_lang_isocode'],'lg_iso_2');
if ($staticLangRow['lg_iso_2']) {
$this->languageIconTitles[$row['uid']]['ISOcode'] = $staticLangRow['lg_iso_2'];
}
}
if (strlen ($row['flag'])) {
$this->languageIconTitles[$row['uid']]['flagIcon'] = @is_file($flagAbsPath.$row['flag']) ? $flagIconPath.$row['flag'] : '';
}
}
}
}
......
......@@ -1214,17 +1214,6 @@ class localRecordList extends recordList {
return '&returnUrl='.rawurlencode(t3lib_div::getIndpEnv('REQUEST_URI'));
}
/**
* Return the icon for the language
*
* @param integer Sys language uid
* @return string Language icon
*/
function languageFlag($sys_language_uid) {
return ($this->languageIconTitles[$sys_language_uid]['flagIcon'] ? '<img src="'.$this->languageIconTitles[$sys_language_uid]['flagIcon'].'" class="absmiddle" alt="" />&nbsp;' : '').
htmlspecialchars($this->languageIconTitles[$sys_language_uid]['title']);
}
......
......@@ -89,7 +89,7 @@ $BE_USER->modAccess($MCONF,1);
class SC_mod_web_perm_index {
// External, static:
var $getLevels=3; // Number of levels to enable recursive settings for
var $getLevels = 10; // Number of levels to enable recursive settings for
// Internal, static:
var $MCONF=array(); // Module config
......
......@@ -195,10 +195,10 @@ TABLE.typo3-dyntabmenu TD A { color:grey; text-decoration:none; display: block;
TABLE.typo3-dyntabmenu TD.tabact A { color:#000; padding-left:10px; padding-right:10px; }
TABLE.typo3-dyntabmenu TD A:hover { color:#000; background: #f6eab7; text-decoration:none; }
DIV.typo3-dyntabmenu-divs-foldout DIV.c-tablayer {margin-left: 20px;}
DIV.typo3-dyntabmenu-divs-foldout DIV.tab { background: #c4d4cd; background-image: url(gfx/ol/plusonly.gif); background-repeat: no-repeat; border: solid black 1px; }
DIV.typo3-dyntabmenu-divs-foldout DIV.tabact { background: #e7dba8; background-image: url(gfx/ol/minusonly.gif); background-repeat: no-repeat; border: solid black 1px; margin-top: 5px; }
DIV.typo3-dyntabmenu-divs-foldout DIV.disabled { color:#999999; border: solid black 1px; background: #cccccc; padding: 2px 2px 2px 22px; }
DIV.typo3-dyntabmenu-divs-foldout DIV.tab A, DIV.typo3-dyntabmenu-divs-foldout DIV.tabact A { text-decoration:none; display: block; padding: 2px 2px 2px 22px; }
DIV.typo3-dyntabmenu-divs-foldout DIV.tab { background: #c4d4cd; background-image: url(gfx/ol/plusbullet.gif); background-repeat: no-repeat; border: solid black 1px; }
DIV.typo3-dyntabmenu-divs-foldout DIV.tabact { background: #e7dba8; background-image: url(gfx/ol/minusbullet.gif); background-repeat: no-repeat; border: solid black 1px; margin-top: 5px; }
DIV.typo3-dyntabmenu-divs-foldout DIV.disabled { color:#999999; border: solid black 1px; background: #cccccc; padding: 2px 2px 2px 18px; }
DIV.typo3-dyntabmenu-divs-foldout DIV.tab A, DIV.typo3-dyntabmenu-divs-foldout DIV.tabact A { text-decoration:none; display: block; padding: 2px 2px 2px 18px; }
/* Logo frame (alt_toplogo.php) */
......
......@@ -373,6 +373,8 @@ class tx_cms_layout extends recordList {
function getTable_tt_content($id) {
global $TCA;
$this->initializeLanguages();
// Initialize:
$RTE = $GLOBALS['BE_USER']->isRTE();
$lMarg=1;
......@@ -409,7 +411,7 @@ class tx_cms_layout extends recordList {
// For EACH languages... :
foreach($langListArr as $lP) { // If NOT languageMode, then we'll only be through this once.
$showLanguage = ' AND sys_language_uid='.$lP;
$showLanguage = $this->defLangBinding && $lP==0 ? ' AND sys_language_uid IN (0,-1)' : ' AND sys_language_uid='.$lP;
$cList = explode(',',$this->tt_contentConfig['cols']);
$content = array();
$head = array();
......@@ -437,7 +439,7 @@ class tx_cms_layout extends recordList {
if (!$lP) $defLanguageCount[$key][] = $row['uid'];
$editUidList.= $row['uid'].',';
$singleElementHTML.= $this->tt_content_drawHeader($row,$this->tt_contentConfig['showInfo']?15:5);
$singleElementHTML.= $this->tt_content_drawHeader($row,$this->tt_contentConfig['showInfo']?15:5, $this->defLangBinding && $lP>0, TRUE);
$isRTE = $RTE && $this->isRTEforField('tt_content',$row,'bodytext');
$singleElementHTML.= $this->tt_content_drawItem($row,$isRTE);
......@@ -590,98 +592,104 @@ class tx_cms_layout extends recordList {
$out.= t3lib_BEfunc::cshItem($this->descrTable,'language_list',$GLOBALS['BACK_PATH']);
}
} else { // SINGLE column mode (columns shown beneath each other):
#debug('single column');
if ($this->tt_contentConfig['sys_language_uid']==0 || !$this->defLangBinding) {
// Initialize:
$showLanguage = ' AND sys_language_uid='.$this->tt_contentConfig['sys_language_uid'];
$cList = explode(',',$this->tt_contentConfig['showSingleCol']);
$content=array();
$out='';
// Initialize:
$showLanguage = $this->defLangBinding && $this->tt_contentConfig['sys_language_uid']==0 ? ' AND sys_language_uid IN (0,-1)' : ' AND sys_language_uid='.$this->tt_contentConfig['sys_language_uid'];
// Expand the table to some preset dimensions:
$out.='
<tr>
<td><img src="clear.gif" width="'.$lMarg.'" height="1" alt="" /></td>
<td valign="top"><img src="clear.gif" width="150" height="1" alt="" /></td>
<td><img src="clear.gif" width="10" height="1" alt="" /></td>
<td valign="top"><img src="clear.gif" width="300" height="1" alt="" /></td>
</tr>';
$cList = explode(',',$this->tt_contentConfig['showSingleCol']);
$content=array();
$out='';
// Traverse columns to display top-on-top
while(list($counter,$key)=each($cList)) {
// Select content elements:
$queryParts = $this->makeQueryArray('tt_content', $id, 'AND colPos='.intval($key).$showHidden.$showLanguage);
$result = $GLOBALS['TYPO3_DB']->exec_SELECT_queryArray($queryParts);
$c = 0;
$rowArr = $this->getResult($result);
$rowOut = '';
// If it turns out that there are not content elements in the column, then display a big button which links directly to the wizard script:
if ($this->doEdit && $this->option_showBigButtons && !intval($key) && !$GLOBALS['TYPO3_DB']->sql_num_rows($result)) {
$onClick="document.location='db_new_content_el.php?id=".$id.'&colPos='.intval($key).'&sys_language_uid='.$lP.'&uid_pid='.$id.'&returnUrl='.rawurlencode(t3lib_div::getIndpEnv('REQUEST_URI'))."';";
$theNewButton=$GLOBALS['SOBE']->doc->t3Button($onClick,$GLOBALS['LANG']->getLL('newPageContent'));
$theNewButton='<img src="clear.gif" width="1" height="5" alt="" /><br />'.$theNewButton;
} else $theNewButton='';
// Traverse any selected elements:
foreach($rowArr as $row) {
$c++;
$editUidList.=$row['uid'].',';
$isRTE=$RTE && $this->isRTEforField('tt_content',$row,'bodytext');
// Create row output:
$rowOut.='
<tr>
<td></td>
<td valign="top">'.$this->tt_content_drawHeader($row).'</td>
<td></td>
<td valign="top">'.$this->tt_content_drawItem($row,$isRTE).'</td>
</tr>';
// Expand the table to some preset dimensions:
$out.='
<tr>
<td><img src="clear.gif" width="'.$lMarg.'" height="1" alt="" /></td>
<td valign="top"><img src="clear.gif" width="150" height="1" alt="" /></td>
<td><img src="clear.gif" width="10" height="1" alt="" /></td>
<td valign="top"><img src="clear.gif" width="300" height="1" alt="" /></td>
</tr>';
// Traverse columns to display top-on-top
while(list($counter,$key)=each($cList)) {
// Select content elements:
$queryParts = $this->makeQueryArray('tt_content', $id, 'AND colPos='.intval($key).$showHidden.$showLanguage);
$result = $GLOBALS['TYPO3_DB']->exec_SELECT_queryArray($queryParts);
$c = 0;
$rowArr = $this->getResult($result);
$rowOut = '';
// If it turns out that there are not content elements in the column, then display a big button which links directly to the wizard script:
if ($this->doEdit && $this->option_showBigButtons && !intval($key) && !$GLOBALS['TYPO3_DB']->sql_num_rows($result)) {
$onClick="document.location='db_new_content_el.php?id=".$id.'&colPos='.intval($key).'&sys_language_uid='.$lP.'&uid_pid='.$id.'&returnUrl='.rawurlencode(t3lib_div::getIndpEnv('REQUEST_URI'))."';";
$theNewButton=$GLOBALS['SOBE']->doc->t3Button($onClick,$GLOBALS['LANG']->getLL('newPageContent'));
$theNewButton='<img src="clear.gif" width="1" height="5" alt="" /><br />'.$theNewButton;
} else $theNewButton='';
// Traverse any selected elements:
foreach($rowArr as $row) {
$c++;
$editUidList.=$row['uid'].',';
$isRTE=$RTE && $this->isRTEforField('tt_content',$row,'bodytext');
// If the element was not the last element, add a divider line:
if ($c != $GLOBALS['TYPO3_DB']->sql_num_rows($result)) {
// Create row output:
$rowOut.='
<tr>
<td></td>
<td colspan="3"><img'.t3lib_iconWorks::skinImg($this->backPath,'gfx/stiblet_medium2.gif','width="468" height="1"').' class="c-divider" alt="" /></td>
</tr>';
<tr>
<td></td>
<td valign="top">'.$this->tt_content_drawHeader($row).'</td>
<td></td>
<td valign="top">'.$this->tt_content_drawItem($row,$isRTE).'</td>
</tr>';
// If the element was not the last element, add a divider line:
if ($c != $GLOBALS['TYPO3_DB']->sql_num_rows($result)) {
$rowOut.='
<tr>
<td></td>
<td colspan="3"><img'.t3lib_iconWorks::skinImg($this->backPath,'gfx/stiblet_medium2.gif','width="468" height="1"').' class="c-divider" alt="" /></td>
</tr>';
}
}
// Add spacer between sections in the vertical list
if ($counter) {
$out.='
<tr>
<td></td>
<td colspan="3"><br /><br /><br /><br /></td>
</tr>';
}
}
// Add spacer between sections in the vertical list
if ($counter) {
// Add section header:
$newP = $this->newContentElementOnClick($id,$key,$this->tt_contentConfig['sys_language_uid']);
$out.='
<!-- Column header: -->
<tr>
<td></td>
<td colspan="3"><br /><br /><br /><br /></td>
<td valign="top" colspan="3">'.
$this->tt_content_drawColHeader(t3lib_BEfunc::getProcessedValue('tt_content','colPos',$key), ($this->doEdit&&count($rowArr)?'&edit[tt_content]['.$editUidList.']=edit'.$pageTitleParamForAltDoc:''), $newP).
$theNewButton.
'<br /></td>
</tr>';
}
// Add section header:
$newP = $this->newContentElementOnClick($id,$key,$this->tt_contentConfig['sys_language_uid']);
$out.='
// Finally, add the content from the records in this column:
$out.=$rowOut;
}
<!-- Column header: -->
<tr>
<td></td>
<td valign="top" colspan="3">'.
$this->tt_content_drawColHeader(t3lib_BEfunc::getProcessedValue('tt_content','colPos',$key), ($this->doEdit&&count($rowArr)?'&edit[tt_content]['.$editUidList.']=edit'.$pageTitleParamForAltDoc:''), $newP).
$theNewButton.
'<br /></td>
</tr>';
// Finally, wrap all table rows in one, big table:
$out = '
<table border="0" cellpadding="0" cellspacing="0" width="400" class="typo3-page-columnsMode">
'.$out.'
</table>';