TinyPortal
Development => Support => Topic started by: dimdom on November 24, 2008, 01:14:18 PM
I use this code to a front page block in Tiny Portal ( 0.9.8 ) to show recent images in SMF Gallery.
global $scripturl,$db_prefix,$modSettings,$boardurl;
echo'<table cellspacing="0" cellpadding="3" border="0" align="center" width="90%"><tr>';
if(empty($modSettings['gallery_url']))
{
$modSettings['gallery_url'] = $boardurl . '/gallery/';
}
$request = db_query("SELECT thumbfilename,ID_PICTURE FROM {$db_prefix}gallery_pic GROUP BY thumbfilename ORDER BY date DESC LIMIT 6", __FILE__,__LINE__);
while ($row = mysql_fetch_assoc($request))
echo' <center><td align="center" colspan="3"><a href="', $scripturl, '?action=gallery;sa=view;id=',
$row['ID_PICTURE'], '"><img src="', $modSettings['gallery_url'] .
$row['thumbfilename'] ,'" /></a></center>';
echo'</td></tr>';
echo'</table></br>';
mysql_free_result($request);
How can I exclude certain categories from fetching pictures to that block?
Thank you in advance!
By using Thurnoks code for the SMF gallery he have posted in our block code and snippets board, search his posts in that board and you will find it :up:
Thanks!
I found it.