Project

General

Profile

Feature #16613 ยป 4316.patch

Administrator Admin, 2006-10-02 11:13

View differences:

typo3/sysext/cms/tslib/class.tslib_content_new.php Mon Oct 2 11:05:07 2006
// imageFileLink:
if ($content==$string && @is_file($imageFile)) {
$params = '';
$conf['title'] = trim($this->stdWrap($conf['title'],$conf['title.']));
$conf['alt'] = trim($this->stdWrap($conf['alt'],$conf['alt.']));
$metaCharset = $GLOBALS['TSFE']->metaCharset;
if ($conf['width']) {$params.='&width='.rawurlencode($conf['width']);}
if ($conf['height']) {$params.='&height='.rawurlencode($conf['height']);}
if ($conf['effects']) {$params.='&effects='.rawurlencode($conf['effects']);}
......
if ($conf['bodyTag']) {$params.='&bodyTag='.rawurlencode($conf['bodyTag']);}
if ($conf['title']) {$params.='&title='.rawurlencode($conf['title']);}
if ($conf['alt']) {$params.='&alt='.rawurlencode($conf['alt']);}
if ($conf['wrap']) {$params.='&wrap='.rawurlencode($conf['wrap']);}
$params.='&metaCharset='.rawurlencode($metaCharset);
$md5_value = md5(
$imageFile.'|'.
......
$conf['effects'].'|'.
$conf['bodyTag'].'|'.
$conf['title'].'|'.
$conf['alt'].'|'.
$conf['wrap'].'|'.
$metaCharset.'|'.
$GLOBALS['TYPO3_CONF_VARS']['SYS']['encryptionKey'].'|');
$params.= '&md5='.$md5_value;
-- typo3/sysext/cms/tslib/showpic.php Mon Sep 18 13:31:04 2006
++ typo3/sysext/cms/tslib/showpic_new.php Mon Oct 2 11:02:29 2006
......
$this->frame = t3lib_div::_GP('frame');
$this->bodyTag = t3lib_div::_GP('bodyTag');
$this->title = t3lib_div::_GP('title');
$this->alt = t3lib_div::_GP('alt');
$this->wrap = t3lib_div::_GP('wrap');
$this->metaCharset = t3lib_div::_GP('metaCharset');
$this->md5 = t3lib_div::_GP('md5');
// ***********************
......
$this->effects.'|'.
$this->bodyTag.'|'.
$this->title.'|'.
$this->alt.'|'.
$this->wrap.'|'.
$this->metaCharset.'|'.
$GLOBALS['TYPO3_CONF_VARS']['SYS']['encryptionKey'].'|');
if ($md5_value!=$this->md5) {
......
<html>
<head>
<title>'.htmlspecialchars($this->title ? $this->title : "Image").'</title>
<meta http-equiv="Content-Type" content="text/html; charset='.$this->metaCharset.'" />
</head>
'.($this->bodyTag ? $this->bodyTag : '<body>');
if (is_array($imgInfo)) {
$wrapParts = explode('|',$this->wrap);
$this->content.=trim($wrapParts[0]).$img->imgTag($imgInfo).trim($wrapParts[1]);
$this->content.=trim($wrapParts[0]).'<img src="'.$imgInfo[3].'" width="'.$imgInfo[0].'" height="'.$imgInfo[1].'" border="0" alt="'.htmlspecialchars($this->alt).'" title="'.htmlspecialchars($this->title).'" />'.trim($wrapParts[1]);
}
$this->content.='
</body>
    (1-1/1)