Commit 892fd24a authored by Kasper Skårhøj's avatar Kasper Skårhøj
Browse files

* Added new CSH entries at various places using a new method in t3lib_BEfunc. The CSH entries are still empty and needs to be completed.


git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@329 709f56b5-9817-0410-a4d7-c38de5d9e867
parent b6e2908d
2004-05-28 Kasper Skårhøj,,, <kasper@typo3.com>
* Added new CSH entries at various places using a new method in t3lib_BEfunc. The CSH entries are still empty and needs to be completed.
2004-05-28 Kasper Skårhøj,,, <kasper@typo3.com>
* Added visual response to backend module selection in the menus; The class attribute of the menu items is changed when a module is selected. The default stylesheet is modified so this results in the current module being highlighted in the menu.
......
......@@ -1865,9 +1865,9 @@ class t3lib_BEfunc {
function helpTextIcon($table,$field,$BACK_PATH,$force=0) {
global $TCA_DESCR,$BE_USER;
if (is_array($TCA_DESCR[$table]) && is_array($TCA_DESCR[$table]['columns'][$field]) && ($BE_USER->uc['edit_showFieldHelp']=='icon' || $force)) {
$onClick = 'vHWin=window.open(\''.$BACK_PATH.'view_help.php?tfID='.($table.'.'.$field).'\',\'viewFieldHelp\',\'height=300,width=250,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
$onClick = 'vHWin=window.open(\''.$BACK_PATH.'view_help.php?tfID='.($table.'.'.$field).'\',\'viewFieldHelp\',\'height=400,width=600,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
return '<a href="#" onclick="'.htmlspecialchars($onClick).'">'.
'<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/helpbubble.gif','width="14" height="14"').' hspace="2" border="0" class="absmiddle"'.($GLOBALS['CLIENT']['FORMSTYLE']?' style="cursor:help;"':'').' alt="" />'.
'<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/helpbubble.gif','width="14" height="14"').' hspace="2" border="0" class="typo3-csh-icon" alt="" />'.
'</a>';
}
}
......@@ -1881,15 +1881,77 @@ class t3lib_BEfunc {
* @param string Table name
* @param string Field name
* @param string Back path
* @param string Additional style-attribute content for wrapping table
* @return string HTML content for help text
*/
function helpText($table,$field,$BACK_PATH) {
function helpText($table,$field,$BACK_PATH,$styleAttrib='') {
global $TCA_DESCR,$BE_USER;
if (is_array($TCA_DESCR[$table]) && is_array($TCA_DESCR[$table]['columns'][$field]) && $BE_USER->uc['edit_showFieldHelp']=='text') {
$fDat = $TCA_DESCR[$table]['columns'][$field];
return '<table border="0" cellpadding="2" cellspacing="0" width="90%"><tr><td valign="top" width="14">'.t3lib_BEfunc::helpTextIcon($table,$field,$BACK_PATH,
$fDat['details']||$fDat['syntax']||$fDat['image_descr']||$fDat['image']||$fDat['seeAlso']
).'</td><td valign="top">'.$fDat['description'].'</td></tr></table>';
// Get Icon:
$editIcon = t3lib_BEfunc::helpTextIcon(
$table,
$field,
$BACK_PATH,
TRUE
);
// Add title?
$text =
($fDat['alttitle'] ? '<h4>'.$fDat['alttitle'].'</h4>' : '').
$fDat['description'];
// Additional styles?
$params = $styleAttrib ? ' style="'.$styleAttrib.'"' : '';
// Compile table with CSH information:
return '<table border="0" cellpadding="2" cellspacing="0" class="typo3-csh-inline"'.$params.'>
<tr>
<td valign="top" width="14">'.$editIcon.'</td>
<td valign="top">'.$text.'</td>
</tr>
</table>';
}
}
/**
* API for getting CSH icons/text for use in backend modules.
* TCA_DESCR will be loaded if it isn't already
* Usage: ?
*
* @param string Table name ('_MOD_'+module name)
* @param string Field name (CSH locallang main key)
* @param string Back path
* @param string Wrap code for icon-mode, splitted by "|". Not used for full-text mode.
* @param boolean If set, the full text will never be shown (only icon). Useful for places where it will break the page if the table with full text is shown.
* @param string Additional style-attribute content for wrapping table (full text mode only)
* @return string HTML content for help text
* @see helpText(), helpTextIcon()
*/
function cshItem($table,$field,$BACK_PATH,$wrap='',$onlyIconMode=FALSE, $styleAttrib='') {
global $TCA_DESCR, $LANG, $BE_USER;
if ($BE_USER->uc['edit_showFieldHelp']) {
$LANG->loadSingleTableDescription($table);
if (is_array($TCA_DESCR[$table])) {
// Creating CSH icon and short description:
$fullText = t3lib_BEfunc::helpText($table,$field,$BACK_PATH,$styleAttrib);
$icon = t3lib_BEfunc::helpTextIcon($table,$field,$BACK_PATH,$onlyIconMode);
if ($fullText && !$onlyIconMode) {
$output = $fullText;
} else {
#$output = '<span style="position:absolute; filter: alpha(opacity=50); -moz-opacity: 0.50;">'.$icon.'</span>';
$output = $icon;
if ($output && $wrap) {
$wrParts = explode('|',$wrap);
$output = $wrParts[0].$output.$wrParts[1];
}
}
return $output;
}
}
}
......
......@@ -91,8 +91,9 @@ class t3lib_browseTree extends t3lib_treeView {
$this->title = $GLOBALS['TYPO3_CONF_VARS']['SYS']['sitename'];
$this->MOUNTS = $GLOBALS['WEBMOUNTS'];
$this->fieldArray = array_merge($this->fieldArray,array('doktype','php_tree_stop'));
if (t3lib_extMgm::isLoaded('cms')) {
$this->fieldArray=array_merge($this->fieldArray,array('doktype','php_tree_stop','hidden','starttime','endtime','fe_group','module','extendToSubpages'));
$this->fieldArray = array_merge($this->fieldArray,array('hidden','starttime','endtime','fe_group','module','extendToSubpages'));
}
}
......
......@@ -3183,7 +3183,7 @@ class t3lib_TCEforms {
*/
function helpTextIcon($table,$field,$force=0) {
if ($this->globalShowHelp && $GLOBALS['TCA_DESCR'][$table]['columns'][$field] && (($this->edit_showFieldHelp=='icon'&&!$this->doLoadTableDescr($table)) || $force)) {
$aOnClick = 'vHWin=window.open(\''.$this->backPath.'view_help.php?tfID='.($table.'.'.$field).'\',\'viewFieldHelp\',\'height=300,width=250,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
$aOnClick = 'vHWin=window.open(\''.$this->backPath.'view_help.php?tfID='.($table.'.'.$field).'\',\'viewFieldHelp\',\'height=400,width=600,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
return '<a href="#" onclick="'.htmlspecialchars($aOnClick).'">'.
'<img'.t3lib_iconWorks::skinImg($this->backPath,'gfx/helpbubble.gif','width="14" height="14"').' hspace="2" border="0" class="absmiddle"'.($GLOBALS['CLIENT']['FORMSTYLE']?' style="cursor:help;"':'').' alt="" />'.
'</a>';
......
......@@ -372,6 +372,7 @@ t3lib_extMgm::addLLrefForTCAdescr('be_users','EXT:lang/locallang_csh_be_users.ph
t3lib_extMgm::addLLrefForTCAdescr('be_groups','EXT:lang/locallang_csh_be_groups.php');
t3lib_extMgm::addLLrefForTCAdescr('sys_filemounts','EXT:lang/locallang_csh_sysfilem.php');
t3lib_extMgm::addLLrefForTCAdescr('_MOD_tools_em','EXT:lang/locallang_csh_em.php'); // Extension manager
t3lib_extMgm::addLLrefForTCAdescr('xMOD_csh_corebe','EXT:lang/locallang_csh_corebe.php'); // General Core
/**
......
......@@ -252,16 +252,17 @@ class SC_alt_db_navframe {
// Produce browse-tree:
$tree = $this->pagetree->getBrowsableTree();
$this->content='';
$this->content.=$this->doc->startPage('Page tree');
$this->content.=$tree;
$this->content.='
$this->content = '';
$this->content.= $this->doc->startPage('Page tree');
$this->content.= $tree;
$this->content.= '
<p class="c-refresh">
<a href="'.htmlspecialchars(t3lib_div::getIndpEnv('REQUEST_URI')).'">'.
'<img'.t3lib_iconWorks::skinImg('','gfx/refresh_n.gif','width="14" height="14"').' title="'.$LANG->sL('LLL:EXT:lang/locallang_core.php:labels.refresh',1).'" alt="" />'.
$LANG->sL('LLL:EXT:lang/locallang_core.php:labels.refresh',1).'</a>
</p>
<br />';
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'pagetree', $GLOBALS['BACK_PATH']);
// Adding highlight - JavaScript
if ($this->doHighlight) $this->content .=$this->doc->wrapScriptTags('
......
......@@ -475,11 +475,15 @@ class SC_alt_doc {
$formContent = $this->compileForm($panel,$docSel,$cMenu,$editForm);
$this->content.=$this->tceforms->printNeededJSFunctions_top().
$formContent.
$this->tceforms->printNeededJSFunctions();
$this->content.=$this->functionMenus();
$this->content.=$this->shortCutLink();
$this->content.= $this->tceforms->printNeededJSFunctions_top().
$formContent.
$this->tceforms->printNeededJSFunctions();
$this->content.= $this->functionMenus();
// Add CSH:
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'TCEforms', $GLOBALS['BACK_PATH'],'<br/>|');
$this->content.= $this->shortCutLink();
$this->tceformMessages();
}
......
......@@ -171,16 +171,17 @@ class SC_alt_file_navframe {
// Produce browse-tree:
$tree=$this->foldertree->getBrowsableTree();
$this->content='';
$this->content.=$this->doc->startPage('Folder tree');
$this->content.=$tree;
$this->content.='
$this->content = '';
$this->content.= $this->doc->startPage('Folder tree');
$this->content.= $tree;
$this->content.= '
<p class="c-refresh">
<a href="'.htmlspecialchars(t3lib_div::getIndpEnv('REQUEST_URI')).'">'.
'<img'.t3lib_iconWorks::skinImg('','gfx/refresh_n.gif','width="14" height="14"').' title="'.$LANG->sL('LLL:EXT:lang/locallang_core.php:labels.refresh',1).'" alt="" />'.
$LANG->sL('LLL:EXT:lang/locallang_core.php:labels.refresh',1).'</a>
</p>
<br />';
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'filetree', $GLOBALS['BACK_PATH']);
// Adding highlight - JavaScript
if ($this->doHighlight) $this->content .=$this->doc->wrapScriptTags('
......
......@@ -112,7 +112,8 @@ class SC_alt_menu {
// Printing the menu
$alt_menuObj = t3lib_div::makeInstance('alt_menu_functions');
$this->content.=$alt_menuObj->topMenu($this->loadModules->modules);
$this->content.= $alt_menuObj->topMenu($this->loadModules->modules);
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'menu_modules', $GLOBALS['BACK_PATH']);
// clear cache commands for Admins
if($BE_USER->isAdmin()) {
......@@ -126,7 +127,10 @@ class SC_alt_menu {
<div id="typo3-alt-menu-php-adminFunc">';
// Header: Admin functions
$this->content.='<h2 class="bgColor5">'.$GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.php:rm.adminFunctions',1).'</h2>';
$this->content.=
'<h2 class="bgColor5">'.
$GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.php:rm.adminFunctions',1).
'</h2>';
// Table with those admin functions
$this->content.='
......@@ -149,6 +153,7 @@ class SC_alt_menu {
$this->content.='
</table>';
$this->content.=t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'menu_adminFunction', $GLOBALS['BACK_PATH']);
$this->content.='
</div>
';
......
......@@ -302,7 +302,10 @@ class SC_alt_shortcut {
($this->editError?'&nbsp;<strong><span class="typo3-red">'.htmlspecialchars($this->editError).'</span></strong>':'').
(is_array($this->theEditRec)?'&nbsp;<strong>'.$LANG->getLL('shortcut_loadEdit',1).' \''.t3lib_BEfunc::getRecordTitle('pages',$this->theEditRec,1).'\'</strong> ('.htmlspecialchars($this->editPath).')':'').
'</td>';
} else $editIdCode='';
} else $editIdCode = '';
// Adding CSH:
$editIdCode.= '<td>&nbsp;'.t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'shortcuts', $GLOBALS['BACK_PATH'],'',TRUE).'</td>';
$this->content.='
......
......@@ -266,6 +266,7 @@ class recordList extends t3lib_recordList {
</tr>
</table>
'.$formElements[1];
$content.=t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'list_searchbox', $GLOBALS['BACK_PATH'],'|<br/>');
return $content;
}
......
......@@ -388,6 +388,9 @@ class localRecordList extends recordList {
$theData[$titleCol] = $this->linkWrapTable($table,'<span class="c-table">'.$GLOBALS['LANG']->sL($TCA[$table]['ctrl']['title'],1).'</span> ('.$this->totalItems.') <img'.t3lib_iconWorks::skinImg($this->backPath,'gfx/'.($this->table?'minus':'plus').'bullet_list.gif','width="18" height="12"').' hspace="10" class="absmiddle" title="'.$GLOBALS['LANG']->getLL(!$this->table?'expandView':'contractView',1).'" alt="" />');
}
// CSH:
$theData[$titleCol].= t3lib_BEfunc::cshItem($table,'',$this->backPath);
if ($LOISmode) {
$out.='
<tr>
......@@ -397,7 +400,7 @@ class localRecordList extends recordList {
if ($GLOBALS['BE_USER']->uc["edit_showFieldHelp"]) {
$GLOBALS['LANG']->loadSingleTableDescription($table);
if (isset($GLOBALS['TCA_DESCR'][$table]['columns'][''])) {
$onClick = 'vHWin=window.open(\'view_help.php?tfID='.$table.'.\',\'viewFieldHelp\',\'height=300,width=250,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
$onClick = 'vHWin=window.open(\'view_help.php?tfID='.$table.'.\',\'viewFieldHelp\',\'height=400,width=600,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
$out.='
<tr>
<td class="c-tableDescription">'.t3lib_BEfunc::helpTextIcon($table,'',$this->backPath,TRUE).$GLOBALS['TCA_DESCR'][$table]['columns']['']['description'].'</td>
......
......@@ -194,9 +194,13 @@ class recordHistory {
<table border="0" cellpadding="2" cellspacing="2" id="typo3-history-item">
'.implode('',$lines).'
</table>';
$theCode.='
<br /><img'.t3lib_iconWorks::skinImg('','gfx/icon_note.gif','width="18" height="16"').' align="top" alt="" />'.$LANG->getLL('differenceMsg').'<br /><br />';
// Add CSH:
$theCode.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'history_entry', $GLOBALS['BACK_PATH'],'');
// Create the module section:
$content.=$SOBE->doc->section($LANG->getLL('changes'),$theCode,0,1);
}
......@@ -501,7 +505,10 @@ class recordHistory {
</table>';
// Add message about the difference view.
$theCode.='<br /><img'.t3lib_iconWorks::skinImg('','gfx/icon_note.gif','width="18" height="16"').' align="top" alt="" />'.$LANG->getLL('differenceMsg').'<br /><br />';
$theCode.= '<br /><img'.t3lib_iconWorks::skinImg('','gfx/icon_note.gif','width="18" height="16"').' align="top" alt="" />'.$LANG->getLL('differenceMsg').'<br /><br />';
// Add CSH:
$theCode.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'history_'.($this->sumUp ? 'sum' : 'log'), $GLOBALS['BACK_PATH'],'');
// Add the whole content as a module section:
return $SOBE->doc->section($LANG->getLL('changes'),$theCode,0,1);
......
......@@ -345,6 +345,9 @@ class SC_db_list {
$this->content.= $dblist->HTMLcode;
$this->content.= '<input type="hidden" name="cmd_table" /><input type="hidden" name="cmd" /></form>';
// List Module CSH:
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'list_module', $GLOBALS['BACK_PATH'],'<br/>|');
// If a listing was produced, create the page footer with search form etc:
if ($dblist->HTMLcode) {
......@@ -362,17 +365,20 @@ class SC_db_list {
-->
<div id="typo3-listOptions">
<form action="" method="post">';
$this->content.=t3lib_BEfunc::getFuncCheck($this->id,'SET[bigControlPanel]',$this->MOD_SETTINGS['bigControlPanel'],'db_list.php','').' '.$LANG->getLL('largeControl',1).'<br />';
if ($dblist->showClipboard) {
$this->content.=t3lib_BEfunc::getFuncCheck($this->id,'SET[clipBoard]',$this->MOD_SETTINGS['clipBoard'],'db_list.php','').' '.$LANG->getLL('showClipBoard',1);
}
$this->content.='
$this->content.=t3lib_BEfunc::getFuncCheck($this->id,'SET[bigControlPanel]',$this->MOD_SETTINGS['bigControlPanel'],'db_list.php','').' '.$LANG->getLL('largeControl',1).'<br />';
if ($dblist->showClipboard) {
$this->content.=t3lib_BEfunc::getFuncCheck($this->id,'SET[clipBoard]',$this->MOD_SETTINGS['clipBoard'],'db_list.php','').' '.$LANG->getLL('showClipBoard',1);
}
$this->content.='
</form>
</div>';
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'list_options', $GLOBALS['BACK_PATH']);
// Printing clipboard if enabled:
if ($this->MOD_SETTINGS['clipBoard'] && $dblist->showClipboard) {
$this->content.=$dblist->clipObj->printClipboard();
$this->content.= $dblist->clipObj->printClipboard();
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'list_clipboard', $GLOBALS['BACK_PATH']);
}
// Link for creating new records:
......
......@@ -166,7 +166,7 @@ class SC_db_new {
$this->pagesOnly = t3lib_div::_GP('pagesOnly');
// Create instance of template class for output
$this->doc = t3lib_div::makeInstance('smallDoc');
$this->doc = t3lib_div::makeInstance('mediumDoc');
$this->doc->backPath = $BACK_PATH;
$this->doc->docType= 'xhtml_trans';
$this->doc->JScode='';
......@@ -241,11 +241,6 @@ class SC_db_new {
';
$this->R_URI=$this->returnUrl;
// If CSH is enabled (Context Sensitive Help), load descriptions for 'pages' in any case:
if ($BE_USER->uc['edit_showFieldHelp']) {
$LANG->loadSingleTableDescription('pages');
}
// GENERATE the HTML-output depending on mode (pagesOnly is the page wizard)
if (!$this->pagesOnly) { // Regular new element:
$this->regularNew();
......@@ -279,6 +274,9 @@ class SC_db_new {
<h3>'.htmlspecialchars($LANG->getLL('selectPosition')).':</h3>
';
$this->code.= $posMap->positionTree($this->id,$this->pageinfo,$this->perms_clause,$this->R_URI);
// Add CSH:
$this->code.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'new_pages', $GLOBALS['BACK_PATH'],'<br/>');
}
/**
......@@ -287,42 +285,44 @@ class SC_db_new {
* @return void
*/
function regularNew() {
global $BE_USER,$LANG,$BACK_PATH,$TCA_DESCR,$TCA;
global $BE_USER,$LANG,$BACK_PATH,$TCA;
$doNotShowFullDescr = FALSE;
// Slight spacer from header:
$this->code.='<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/ol/halfline.gif','width="18" height="8"').' alt="" /><br />';
// Initialize array for accumulating table rows:
$tRows = array();
// New pages INSIDE this pages
if ($this->newPagesInto && $this->isTableAllowedForThisPage($this->pageinfo, 'pages') && $BE_USER->check('tables_modify','pages')) {
// Create link to new page inside:
$t='pages';
$v=$TCA[$t];
$this->code.='<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/ol/join.gif','width="18" height="16"').' alt="" />'.
$this->linkWrap(
'<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/i/'.($v['ctrl']['iconfile'] ? $v['ctrl']['iconfile'] : $t.'.gif'),'width="18" height="16"').' alt="" />'.
$t = 'pages';
$v = $TCA[$t];
$rowContent = '<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/ol/join.gif','width="18" height="16"').' alt="" />'.
$this->linkWrap(
'<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/i/'.($v['ctrl']['iconfile'] ? $v['ctrl']['iconfile'] : $t.'.gif'),'width="18" height="16"').' alt="" />'.
$LANG->sL($v['ctrl']['title'],1).' ('.$LANG->sL('LLL:EXT:lang/locallang_core.php:db_new.php.inside',1).')',
$t,
$this->id);
// Link to CSH:
if (isset($TCA_DESCR[$t]['columns'][''])) {
$onClick = 'vHWin=window.open(\'view_help.php?tfID='.$t.'.\',\'viewFieldHelp\',\'height=300,width=250,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
$this->code.='<a href="#" onclick="'.htmlspecialchars($onClick).'">'.
'<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/helpbubble.gif','width="14" height="14"').' class="c-helpImg" align="right"'.$this->doc->helpStyle().' alt="" />'.
'</a>';
}
$this->code.='<br />
';
$this->id).'<br/>';
// Link to page-wizard:
$this->code.='<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/line.gif','width="18" height="16"').' alt="" /><img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/joinbottom.gif','width="18" height="16"').' alt="" />'.
$rowContent.= '<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/line.gif','width="18" height="16"').' alt="" /><img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/joinbottom.gif','width="18" height="16"').' alt="" />'.
'<a href="'.htmlspecialchars(t3lib_div::linkThisScript(array('pagesOnly'=>1))).'">'.
'<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/new_page.gif','width="13" height="12"').' alt="" /> '.
htmlspecialchars($LANG->getLL('clickForWizard')).
'</a><br />
';
$this->code.='<img'.t3lib_iconWorks::skinImg('','gfx/ol/halfline.gif','width="18" height="8"').' alt="" /><br />
'</a>';
// Half-line:
$rowContent.= '<br /><img'.t3lib_iconWorks::skinImg('','gfx/ol/halfline.gif','width="18" height="8"').' alt="" />';
// Compile table row:
$tRows[]='
<tr>
<td nowrap="nowrap">'.$rowContent.'</td>
<td>'.t3lib_BEfunc::cshItem($t,'',$GLOBALS['BACK_PATH'],'',$doNotShowFullDescr).'</td>
</tr>
';
}
......@@ -338,26 +338,13 @@ class SC_db_new {
) {
// Create new link for record:
$this->code.='<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/ol/join.gif','width="18" height="16"').' alt="" />'.
$rowContent = '<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/ol/join.gif','width="18" height="16"').' alt="" />'.
$this->linkWrap(
t3lib_iconWorks::getIconImage($t,array(),$BACK_PATH,'').
$LANG->sL($v['ctrl']['title'],1)
,$t
,$this->id);
// Create CSH link for table:
if ($BE_USER->uc['edit_showFieldHelp']) {
$LANG->loadSingleTableDescription($t);
if (isset($TCA_DESCR[$t]['columns'][''])) {
$onClick = 'vHWin=window.open(\'view_help.php?tfID='.$t.'.\',\'viewFieldHelp\',\'height=300,width=250,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
$this->code.='<a href="#" onclick="'.htmlspecialchars($onClick).'">'.
'<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/helpbubble.gif','width="14" height="14"').' class="c-helpImg" align="right"'.$this->doc->helpStyle().' alt="" />'.
'</a>';
}
}
$this->code.='<br />
';
// If the table is 'tt_content' (from "cms" extension), create link to wizard
if ($t=='tt_content') {
......@@ -366,15 +353,25 @@ class SC_db_new {
$pathToWizard = (t3lib_extMgm::isLoaded($overrideExt)) ? (t3lib_extMgm::extRelPath($overrideExt).'mod1/db_new_content_el.php') : 'sysext/cms/layout/db_new_content_el.php';
$href = $pathToWizard.'?id='.$this->id.'&returnUrl='.rawurlencode($this->R_URI);
$this->code.='<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/line.gif','width="18" height="16"').' alt="" />'.
$rowContent.= '<br /><img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/line.gif','width="18" height="16"').' alt="" />'.
'<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/joinbottom.gif','width="18" height="16"').' alt="" />'.
'<a href="'.htmlspecialchars($href).'"><img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/new_record.gif','width="16" height="12"').' alt="" /> '.
htmlspecialchars($LANG->getLL('clickForWizard')).
'</a><br />
';
$this->code.='<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/halfline.gif','width="18" height="8"').' alt="" /><br />
';
'</a>';
// Half-line added:
$rowContent.= '<br /><img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/ol/halfline.gif','width="18" height="8"').' alt="" />';
}
// Compile table row:
$tRows[] = '
<tr>
<td nowrap="nowrap">'.$rowContent.'</td>
<td>'.t3lib_BEfunc::cshItem($t,'',$GLOBALS['BACK_PATH'],'',$doNotShowFullDescr).'</td>
</tr>
';
}
}
}
......@@ -384,29 +381,39 @@ class SC_db_new {
if ($this->newPagesAfter && $this->isTableAllowedForThisPage($this->pidInfo,'pages') && $BE_USER->check('tables_modify','pages')) {
// Create link to new page after
$t='pages';
$v=$TCA[$t];
$this->code.=$this->linkWrap(
$t = 'pages';
$v = $TCA[$t];
$rowContent = $this->linkWrap(
t3lib_iconWorks::getIconImage($t,array(),$BACK_PATH,'').
$LANG->sL($v['ctrl']['title'],1).' ('.$LANG->sL('LLL:EXT:lang/locallang_core.php:db_new.php.after',1).')',
'pages',
-$this->id
);
// Link to CSH for pages table:
if (isset($TCA_DESCR[$t]['columns'][''])) {
$onClick = 'vHWin=window.open(\'view_help.php?tfID='.$t.'.\',\'viewFieldHelp\',\'height=300,width=250,status=0,menubar=0,scrollbars=1\');vHWin.focus();return false;';
$this->code.='<a href="#" onclick="'.htmlspecialchars($onCLick).'">'.
'<img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/helpbubble.gif','width="14" height="14"').' class="c-helpImg" align="right"'.$this->doc->helpStyle().' alt="" />'.
'</a>';
}
$this->code.='<br />
// Compile table row:
$tRows[] = '
<tr>
<td nowrap="nowrap">'.$rowContent.'</td>
<td>'.t3lib_BEfunc::cshItem($t,'',$GLOBALS['BACK_PATH'],'',$doNotShowFullDescr).'</td>
</tr>
';
} else {
$this->code.='<img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/ol/stopper.gif','width="18" height="16"').' alt="" /><br />
// Compile table row:
$tRows[]='
<tr>
<td><img'.t3lib_iconWorks::skinImg($BACK_PATH,'gfx/ol/stopper.gif','width="18" height="16"').' alt="" /></td>
<td></td>
</tr>
';
}
// Make table:
$this->code.='
<table border="0" cellpadding="0" cellspacing="0" id="typo3-newRecord">
'.implode('',$tRows).'
</table>
';
// Create a link to the new-pages wizard.
if ($this->showNewRecLink('pages')) {
$this->code.='
......@@ -422,6 +429,9 @@ class SC_db_new {
</div>
';
}
// Add CSH:
$this->code.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'new_regular', $GLOBALS['BACK_PATH'],'<br/>');
}
/**
......
......@@ -179,6 +179,9 @@ class SC_file_edit {
</div>
<br />';
// CSH:
$code.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'file_edit', $GLOBALS['BACK_PATH'],'|<br/>');
// Make shortcut:
if ($BE_USER->mayMakeShortcut()) {
$this->MCONF['name']='xMOD_file_edit.php';
......
......@@ -241,6 +241,9 @@ class SC_file_list {
$this->content.= $filelist->HTMLcode;
$this->content.= '<input type="hidden" name="cmd" /></form>';
// FileList Module CSH:
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'filelist_module', $GLOBALS['BACK_PATH'],'<br/>|');
if ($filelist->HTMLcode) { // Making listing options:
$this->content.='
......@@ -260,10 +263,14 @@ class SC_file_list {
$this->content.='
</div>
';
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'filelist_options', $GLOBALS['BACK_PATH']);
// Set clipboard:
if ($this->MOD_SETTINGS['clipBoard']) $this->content.=$filelist->clipObj->printClipboard();
if ($this->MOD_SETTINGS['clipBoard']) {
$this->content.=$filelist->clipObj->printClipboard();
$this->content.= t3lib_BEfunc::cshItem('xMOD_csh_corebe', 'filelist_clipboard', $GLOBALS['BACK_PATH']);
}
}
// Add shortcut
......