<?php
// exoops.info Licence: GPL
include ("../../mainfile.php");
$meta['title'] .= " - ".MP_PARTNER_TITLE;
include (XOOPS_ROOT_PATH."/header.php");
include (XOOPS_ROOT_PATH."/modules/partner/cache/config.php");
global $xoopsTheme,$db;
OpenTable();  ?>
<div align="left"><b><?php echo MP_PARTNER_TITLE_LIST;?></b><br /><br /></div>
<?php 
echo "<table width='100%'>";
$sql = "SELECT id, url, image, title, description, status FROM ".$db->prefix("partner")." WHERE status='1' ";
if ($partnerconfig['random'] == 1) { $sql .= "ORDER BY RAND()"; } 
$result = $db->query($sql);
while ($row = $db->fetchRow($result)) {
	list ($id, $url, $image, $title, $description, $status) = $row;
	echo "<tr><td width='120'><a href='".$url."'><img src='".XOOPS_URL."/modules/partner/cache/images/".$image."' /></a></td><td width='120'>".$title."</td><td>".$description."</td><td>";
} 
echo "</table>";
CloseTable();
include (XOOPS_ROOT_PATH."/footer.php");
?>