Temos pavadinimas: WordPress, Shopify ir PHPFusion programuotojų bendruomenė :: Pro_Download

Parašė BloodKiller· 2007 Lap. 10 21:11:45
#12

Megaukis. :)

openside("Naujausi Siuntiniai");

$result = dbquery("
   SELECT td.*,tdc.*, td.name AS download FROM ".$db_prefix."prodownloads td
   INNER JOIN ".$db_prefix."prodownload_cats tdc ON td.cat=tdc.cat
   ORDER BY datestamp DESC LIMIT 0,10
");

if (dbrows($result) != 0) {
   while($data = dbarray($result)) {
      $itemsubject = trimlink($data['download'], 23);
      echo "<img src='".THEME."images/bullet.gif' alt=''> <a href='".INFUSIONS."pro_download_panel/download.php?catid=".$data['cat']."&did=".$data['id']."' title='".$data['download']."' class='side'>$itemsubject</a><br>\n";
   }
} else {
   echo "<center>".$locale['004']."</center>\n";
}

closeside();




openside("Populiariausi siuntiniai");
$result = dbquery("SELECT * FROM ".$db_prefix."prodownloads ORDER BY downloads DESC LIMIT 0,10");
if (dbrows($result) != 0) {
   echo "<table width='100%' cellpadding='0' cellspacing='0'>";
   while($data = dbarray($result)) {
      $itemsubject = trimlink($data['name'], 23);
      echo "<tr>\n<td class='small'><img src='".THEME."images/bullet.gif'> <a href='".INFUSIONS."download.php?catid=".$data['cat']."&did=".$data['id']."' title='".$data['name']."' class='side'>$itemsubject</a></td>\n
<td align='right'>".$data['downloads']." siuntimai</td>\n</tr>\n";
   }
   echo "</table>";
} else {
   echo "<center>".$locale['004']."</center>\n";
}
closeside();