If you dont like to be transfered to the gallery if you click the thumb picture in the island you can use the code down there. This little modification bring up the full size picture in the lightbox view include the file description (if exists). My next goal: the click should bring you to the gallery and open the selected picture in the lightbox automaticly. A combination of both code boxes. Time will tell ...

Code
/* PHP CODE HERE */
$query = "
	SELECT
		`POST_ID`, `FILE_DIR`, `FILE_NAME` , FILE_DESCRIPTION
	FROM
		`{$config['TABLE_PREFIX']}FILES`
	WHERE
		`FILE_DIR`<>''
	ORDER BY
		rand()
	LIMIT
		1
";
$sth = $dbh->do_query($query,__LINE__,__FILE__);
list($postId,$fDir,$fName,$fDesc) = $dbh->fetch_array($sth);

/* BODY HERE */
$body = <<<EOF
<div class="p2" style="height:180px;overflow:hidden;position:relative;width:180px;display:inline-block;">
<a href="{$config['BASE_URL']}/gallery/$fDir/full/$fName" data-lightbox="gallery" data-title="$fDesc">
<img src="{$config['BASE_URL']}/gallery/$fDir/medium/$fName" alt="" title="" class="p2 cp oi" style="position:absolute;left:-100%;right:-100%;top:-100%;bottom:-100%;margin:auto;min-height:100%;height:180px;">
</a>
</div>
EOF;


my board: http://www.dragonclan-forum.de
my hobby: http://www.biker-reise.de
Ich kann bei Fragen zu UBBthreads in Deutsch weiterhelfen oder es zumindest versuchen