PHP-Code:
<?
if (!isset($fc_gebucht)) $fc_gebucht = '';
if (!isset($fc_menge)) $fc_menge = '';
if (!isset($fc_wert)) $fc_wert = '';
if (!isset($in_fc_gebucht)) $in_fc_gebucht = '';
if (!isset($in_fc_menge)) $in_fc_menge = '';
if (!isset($in_fc_wert)) $in_fc_wert = '';
if (!isset($hfc_gebucht)) $hfc_gebucht = '';
if (!isset($hfc_menge)) $hfc_menge = '';
if (!isset($hfc_wert)) $hfc_wert = '';
if (!isset($in_hfc_gebucht)) $in_hfc_gebucht = '';
if (!isset($in_hfc_menge)) $in_hfc_menge = '';
if (!isset($in_hfc_wert)) $in_hfc_wert = '';
if (!isset($fc_txt_gebucht)) $fc_txt_gebucht = '';
if (!isset($fc_txt_menge)) $fc_txt_menge = '';
if (!isset($fc_txt_wert)) $fc_txt_wert = '';
if (!isset($in_fc_txt_gebucht)) $in_fc_txt_gebucht = '';
if (!isset($in_fc_txt_menge)) $in_fc_txt_menge = '';
if (!isset($in_fc_txt_wert)) $in_fc_txt_wert = '';
//Autosurf Anfang
if (!isset($tra_gebucht)) $tra_gebucht = '';
if (!isset($tra_menge)) $tra_menge = '';
if (!isset($tra_wert)) $tra_wert = '';
if (!isset($in_tra_gebucht)) $in_tra_gebucht = '';
if (!isset($in_tra_menge)) $in_tra_menge = '';
if (!isset($in_tra_wert)) $in_tra_wert = '';
//Autosurf Ende
$ex_hfc = db_query("SELECT * FROM ".$db_prefix."_gebuchte_werbung WHERE menge >= 1 and werbeart = 'highforced' and status = '1'");
while ($count = mysql_fetch_array($ex_hfc)) {
$hfc_gebucht++;
$hfc_menge = $hfc_menge + $count['menge'];
$hfc_wert = $hfc_wert + ($count['verdienst']*$count['menge']);
}
$ex_fc_txt = db_query("SELECT * FROM ".$db_prefix."_gebuchte_werbung WHERE menge >= 1 and werbeart = 'paidlinks' and status = '1'");
while ($count = mysql_fetch_array($ex_fc_txt)) {
$fc_txt_gebucht++;
$fc_txt_menge = $fc_txt_menge + $count['menge'];
$fc_txt_wert = $fc_txt_wert + ($count['verdienst']*$count['menge']);
}
$kontostats = mysql_fetch_array(db_query("SELECT COUNT(uid) AS kd_uid , SUM(kontostand) AS kd_kontostand , SUM(klicks) AS kd_klicks , SUM(angebettelt) AS kd_angebettelt , SUM(kv) AS kd_kv , SUM(bv) AS kd_bv FROM ".$db_prefix."_kontodaten"));
$werberdaten = mysql_fetch_array(db_query("SELECT SUM(gesamt) AS wd_gesamt FROM ".$db_prefix."_werberdaten"));
$ex_fc = db_query("SELECT * FROM ".$db_prefix."_gebuchte_werbung WHERE menge >= 1 and werbeart = 'forcedbanner' and status = '1'");
while ($count = mysql_fetch_array($ex_fc)) {
$fc_gebucht++;
$fc_menge = $fc_menge + $count['menge'];
$fc_wert = $fc_wert + ($count['verdienst']*$count['menge']);
}
//Autosurf Anfang
$ex_tra = db_query("SELECT * FROM ".$db_prefix."_besuchertausch_seiten WHERE uebrig >= 1 and paidlink <= '2'");
while ($count = mysql_fetch_array($ex_tra)) {
$tra_gebucht++;
$tra_menge = $tra_menge + $count['uebrig'];
$tra_wert = $tra_wert + ($count['verdienst']*$count['uebrig']);
}
//Autosurf Ende
$heute = strtotime("".date("m")."/".date("d")."/".date("Y").""); // Format mm.tt.yyyy
$seitenstart = strtotime("01/10/2010"); // Format mm.tt.yyyy
$tage = ($heute - $seitenstart) / 86400;
if ($tage <= 1) $tage = 1;
?>
<?head("Mediadaten - $seitenname");?>
<table width="100%" border="0" cellpadding="1" cellspacing="1">
<tr>
<td width="50%">Start dieser Seite</td>
<td width="50%"><?=date("d.m.Y",$seitenstart);?></td>
</tr>
<tr>
<td width="50%">Guthaben aller User</td>
<td width="50%"><?=@number_format($kontostats['kd_kontostand'],2,",",".");?> <?=$waehrung;?></td>
</tr>
<tr>
<td width="50%">Guthaben Ø pro User</td>
<td width="50%"><?=@number_format($kontostats['kd_kontostand'] / $kontostats['kd_uid'],2,",",".");?> <?=$waehrung;?></td>
</tr>
<tr>
<td width="50%">Angemeldete User</td>
<td width="50%"><?=@number_format($kontostats['kd_uid'],0,",",".");?></td>
</tr>
<tr>
<td width="50%">Anmeldungen pro Tag</td>
<td width="50%"><?=@number_format($kontostats['kd_uid'] / $tage,2,",",".");?></td>
</tr>
</table>
<?foot();?>
<?head("Mediadaten - Diverses");?>
<table width="100%" border="0" cellpadding="1" cellspacing="1">
<tr>
<td width="50%">Forcedklicks aller User</td>
<td width="50%"><?=@number_format($kontostats['kd_klicks'],0,",",".");?> Klicks</td>
</tr>
<tr>
<td width="50%">Verdienst bei allen Forcedklicks</td>
<td width="50%"><?=@number_format($kontostats['kd_kv'],2,",",".");?> <?=$waehrung;?></td>
</tr>
<tr>
<td width="50%">Ø Verdienst pro Klick</td>
<td width="50%"><?=@number_format($kontostats['kd_kv']/$kontostats['kd_klicks'],2,",",".");?> <?=$waehrung;?></td>
</tr>
</table>
<table width="100%" border="0" cellpadding="1" cellspacing="1">
</table>
<table width="100%" border="0" cellpadding="1" cellspacing="1">
<tr>
<td width="50%">Refverdienste für alle Werber</td>
<td width="50%"><?=@number_format($werberdaten['wd_gesamt'],2,",",".");?> <?=$waehrung;?></td>
</tr>
</table>
<?foot();?>
<?head("Mediadaten - Werbung");?>
<table width="100%" border="0" cellpadding="1" cellspacing="1">
<tr>
<td width="50%">HighForcedklick Kampagnen</td>
<td width="50%"><?=@number_format($hfc_gebucht,0,",",".");?> Kampagnen</td>
</tr>
<tr>
<td width="50%">HighForcedklick Restklicks</td>
<td width="50%"><?=@number_format($hfc_menge,0,",",".");?> Klicks</td>
</tr>
<tr>
<td width="50%">HighForcedklicks Gesamtwert</td>
<td width="50%"><?=@number_format($hfc_wert,2,",",".");?> <?=$waehrung;?></td>
</tr>
<tr>
<td colspan="2" width="100%%"><hr size="1" width="100%" color="#800000"></td>
</tr>
<tr>
<td width="50%">Forcedklick Kampagnen</td>
<td width="50%"><?=@number_format($fc_gebucht,0,",",".");?> Kampagnen</td>
</tr>
<tr>
<td width="50%">Forcedklick Restklicks</td>
<td width="50%"><?=@number_format($fc_menge,0,",",".");?> Klicks</td>
</tr>
<tr>
<td width="50%">Forcedklicks Gesamtwert</td>
<td width="50%"><?=@number_format($fc_wert,2,",",".");?> <?=$waehrung;?></td>
</tr>
<tr>
<td colspan="2" width="100%%"><hr size="1" width="100%" color="#800000"></td>
</tr>
<tr>
<td width="50%">Paidlink Kampagnen</td>
<td width="50%"><?=@number_format($fc_txt_gebucht,0,",",".");?> Kampagnen</td>
</tr>
<tr>
<td width="50%">Paidlink Restklicks</td>
<td width="50%"><?=@number_format($fc_txt_menge,0,",",".");?> Klicks</td>
</tr>
<tr>
<td width="50%">Paidlink Gesamtwert</td>
<td width="50%"><?=@number_format($fc_txt_wert,2,",",".");?> <?=$waehrung;?></td>
</tr>
<tr>
<td colspan="2" width="100%%"><hr size="1" width="100%" color="#800000"></td>
</tr>
<tr>
<td width="50%">Autosurf Kampagnen</td>
<td width="50%"><?=@number_format($tra_gebucht,0,",",".");?> Kampagnen</td>
</tr>
<tr>
<td width="50%">Autosurf Restviews</td>
<td width="50%"><?=@number_format($tra_menge,0,",",".");?> Views</td>
</tr>
<tr>
<td width="50%">Autosurf Gesamtwert</td>
<td width="50%"><?=@number_format($tra_wert,2,",",".");?> <?=$waehrung;?></td>
</tr>
</table>
<?foot();?>