Feature #37595 ยป 37595.patch
t3lib/class.t3lib_extmgm.php | ||
---|---|---|
public static function addPlugin($itemArray, $type = 'list_type') {
|
||
$_EXTKEY = $GLOBALS['_EXTKEY'];
|
||
if ($_EXTKEY && !$itemArray[2]) {
|
||
$itemArray[2] = self::extRelPath($_EXTKEY) . 'ext_icon.gif';
|
||
$itemArray[2] = self::extRelPath($_EXTKEY) .
|
||
$GLOBALS['TYPO3_LOADED_EXT'][$_EXTKEY]['ext_icon'];
|
||
}
|
||
t3lib_div::loadTCA('tt_content');
|
||
... | ... | |
'ext_tables.sql',
|
||
'ext_tables_static+adt.sql',
|
||
'ext_typoscript_constants.txt',
|
||
'ext_typoscript_setup.txt'
|
||
'ext_typoscript_setup.txt',
|
||
);
|
||
// Clear file status cache to make sure we get good results from is_dir()
|
||
... | ... | |
}
|
||
}
|
||
}
|
||
// Register found extension icon
|
||
$loadedExtensionInformation[$extensionKey]['ext_icon'] = self::getExtensionIcon(PATH_site . $loadedExtensionInformation[$extensionKey]['siteRelPath']);
|
||
}
|
||
return $loadedExtensionInformation;
|
||
}
|
||
/**
|
||
* Find extension icon
|
||
*
|
||
* @param string $extensionPath Path to extension directory.
|
||
* @param string $full$ReturnFullPath Return full path of file.
|
||
* @return string
|
||
* @throws BadFunctionCallException
|
||
*/
|
||
public static function getExtensionIcon($extensionPath, $ReturnFullPath = FALSE){
|
||
$icon = '';
|
||
$iconFileTypesToCheckFor = array(
|
||
'gif',
|
||
'png',
|
||
'jpg',
|
||
);
|
||
foreach ($iconFileTypesToCheckFor as $fileType){
|
||
if (@is_file($extensionPath . 'ext_icon.' . $fileType)) {
|
||
$icon = 'ext_icon.' . $fileType;
|
||
break;
|
||
}
|
||
}
|
||
return $ReturnFullPath ? $extensionPath . $icon : $icon;
|
||
}
|
||
/**
|
||
* Cache identifier of cached Typo3LoadedExtensionInformation array
|
||
*
|
||
* @return string
|
typo3/db_new.php | ||
---|---|---|
include(t3lib_extMgm::extPath($_EXTKEY) . 'ext_emconf.php');
|
||
$thisTitle = $EM_CONF[$_EXTKEY]['title'];
|
||
}
|
||
$iconFile[$_EXTKEY] = '<img src="' . t3lib_extMgm::extRelPath($_EXTKEY) . 'ext_icon.gif" />';
|
||
$iconFile[$_EXTKEY] = '<img alt="" src="' . t3lib_extMgm::extRelPath($_EXTKEY) .
|
||
$GLOBALS['TYPO3_LOADED_EXT'][$_EXTKEY]['ext_icon'] . '" height="16" />';
|
||
} else {
|
||
$thisTitle = $nameParts[1];
|
||
$iconFile[$_EXTKEY] = '';
|
typo3/sysext/em/classes/extensions/class.tx_em_extensions_list.php | ||
---|---|---|
$list[$key]['doc'] = '<a href="' . htmlspecialchars($manualRelPath) . '" target="_blank">'
|
||
. t3lib_iconWorks::getSpriteIcon('actions-system-extension-documentation') . '</a>';
|
||
}
|
||
$list[$key]['icon'] = @is_file($path . $extKey . '/ext_icon.gif') ? '<img src="' . $relPath . $extKey . '/ext_icon.gif" alt="" height="16" />' : '<img src="clear.gif" alt="" width="16" height="16" />';
|
||
$list[$key]['icon'] = @is_file(t3lib_extMgm::getExtensionIcon($path . $extKey . '/', TRUE)) ?
|
||
'<img src="' . $relPath . $extKey . '/' .
|
||
t3lib_extMgm::getExtensionIcon($path . $extKey . '/') . '" alt="" height="16" />' :
|
||
'<img src="clear.gif" alt="" width="16" height="16" />';
|
||
$list[$key]['categoryShort'] = $list[$key]['category'];
|
||
$list[$key]['category'] = isset($this->categories[$list[$key]['category']]) ? $this->categories[$list[$key]['category']] : $list[$key]['category'];
|
typo3/sysext/em/classes/index.php | ||
---|---|---|
* @return string HTML; Extension title and image.
|
||
*/
|
||
function extensionTitleIconHeader($extKey, $extInfo, $align = 'top') {
|
||
$imgInfo = @getImageSize(tx_em_Tools::getExtPath($extKey, $extInfo['type']) . '/ext_icon.gif');
|
||
$imgInfo = @getImageSize(tx_em_Tools::getExtPath($extKey, $extInfo['type']) . $extInfo['ext_icon']);
|
||
$out = '';
|
||
if (is_array($imgInfo)) {
|
||
$out .= '<img src="' . $GLOBALS['BACK_PATH'] . tx_em_Tools::typeRelPath($extInfo['type']) . $extKey . '/ext_icon.gif" ' . $imgInfo[3] . ' align="' . $align . '" alt="" />';
|
||
$out .= '<img src="' . $GLOBALS['BACK_PATH'] . tx_em_Tools::typeRelPath($extInfo['type']) . $extKey . '/' .
|
||
$extInfo['ext_icon'] .'" ' . $imgInfo[3] . ' align="' . $align . '" alt="" height="16" />';
|
||
}
|
||
$out .= $extInfo['EM_CONF']['title'] ? htmlspecialchars(t3lib_div::fixed_lgd_cs($extInfo['EM_CONF']['title'], 40)) : '<em>' . htmlspecialchars($extKey) . '</em>';
|
||
return $out;
|