[TYPO3] tt_news and Thickbox (jquery)
Aji Johannes
aji.yahya at gmail.com
Thu Dec 13 15:01:46 CET 2007
Hello List,
if you are interested to add Thickbox (jquery_thickbox) to the tt_news
DisplaySingle Images, it is really easy, may be it is not the perfect
solution but it is working fine.
ok first of all install : jquery_thickbox Ext.
then open pi1/class.tx_ttnews.php
search for: function getImageMarkers($markerArray, $row, $lConf,
$textRenderObj)
you will find in the function this line:
$theImgCode .= $this->local_cObj->IMAGE($lConf['image.']) .
$this->local_cObj->stdWrap($imgsCaptions[$cc], $lConf['caption_stdWrap.']);
change it to:
if ($textRenderObj == 'displaySingle') {
$theImgCode .= '<a href="'.$lConf['image.']['file'].'"
class="thickbox" rel="gallery"
title="'.$imgsCaptions[$cc].'">'.$this->local_cObj->IMAGE($lConf['image.'])
."</a>". $this->local_cObj->stdWrap($imgsCaptions[$cc],
$lConf['caption_stdWrap.']);
}else{
$theImgCode .= $this->local_cObj->IMAGE($lConf['image.']) .
$this->local_cObj->stdWrap($imgsCaptions[$cc], $lConf['caption_stdWrap.']);
}
dont forget to disable: image popup in displaySingle, you can do it in
setup.txt
displaySingle.image {
..
...
..
enable = 0
..
}
may be this will help you too, if you want work with jQuery lib.
enjoy ;-)
Regards
Aji
More information about the TYPO3-english
mailing list