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

Parašė tofy· 2008 Gru. 18 20:12:56
#1

biški durnas klausimas... :D
MAn reikai i šita koda iterpti koda kad šalai tu dveiju banneriu ( sistemu) rodytu dar vieną paprasta banneri ?

<?
//Be sure to alter this to suit your site
$bannerheight = '60';
$bannerwidth = '468';


// Check if locale file is available matching the current site locale setting.
if (file_exists(INFUSIONS."banner_panel/locale/".$settings['locale'].".php")) {
   // Load the locale file matching the current site locale setting.
   include_once INFUSIONS."banner_panel/locale/".$settings['locale'].".php";
} else {
   // Load the infusion's default locale file.
   include_once INFUSIONS."banner_panel/locale/Lithuanian.php";
}
global $fusion_prefix, $userdata, $locale;
$bresult = dbquery("select * from ".$db_prefix."banner WHERE status='1'");
$gotbanners = dbrows($bresult);
   if($gotbanners > "0")
   {
   opentable($locale['BRS171']);



echo '<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0">
<tr>
   <td align="center">';
   include_once INFUSIONS.'banner_panel/view.php';
   echo $banner_display;
echo '</td>
</tr>
</table>';
}//if($bresult != "")

include INFUSIONS."pinigu_468_panel/lang.php";
if(dbcount("(*)", "money_banners", "tipas='0'") > 0){
$sql = dbquery("SELECT * FROM ".$db_prefix."money_banners WHERE `parodymai` = `kiekis` and tipas='0'");
while ($baneris = dbarray($sql)){
unlink(INFUSIONS."pinigu_sistema/banners/468x60/".$baneris[imgas]);
dbquery("DELETE FROM ".$db_prefix."money_banners WHERE id = '".$baneris[id]."' and tipas='0'");
}
$sql = dbquery("SELECT * FROM ".$db_prefix."money_banners WHERE tipas='0' ORDER BY RAND() LIMIT 1");

while ($baneris = dbarray($sql)){
echo "<center><a href='".stripinput(htmlspecialchars($baneris[adresas]))."'><img src='".INFUSIONS."pinigu_sistema/banners/468x60/".$baneris[imgas]."' border='0'></a></center>";
$result = dbquery("UPDATE ".$db_prefix."money_banners SET `parodymai` = `parodymai`+ 1 WHERE id=".$baneris[id]."");
}   
}else{
echo "<center><a href='".INFUSIONS."pinigu_sistema/banners468.php'><img src='".INFUSIONS."pinigu_sistema/banners/reklama468.gif' border='0'></a></center>";
}
closetable();
?>





Iškart ačiū ;)

Redagavo tofy· 2008 Gru. 19 23:12:07