$roi = @round($net / $cost * 100);
            $total_roi = @round($total_net / $total_cost * 100);
            //html escape vars
            $html['clicks'] = htmlentities(number_format($clicks), ENT_QUOTES, 'UTF-8');
            $html['leads'] = htmlentities(number_format($leads), ENT_QUOTES, 'UTF-8');
            $html['su_ratio'] = htmlentities($su_ratio . '%', ENT_QUOTES, 'UTF-8');
            $html['payout'] = htmlentities(dollar_format($payout), ENT_QUOTES, 'UTF-8');
            $html['epc'] = htmlentities(dollar_format($epc), ENT_QUOTES, 'UTF-8');
            $html['avg_cpc'] = htmlentities(dollar_format($avg_cpc, $cpv), ENT_QUOTES, 'UTF-8');
            $html['income'] = htmlentities(dollar_format($income), ENT_QUOTES, 'UTF-8');
            $html['cost'] = htmlentities(dollar_format($cost, $cpv), ENT_QUOTES, 'UTF-8');
            $html['net'] = htmlentities(dollar_format($net, $cpv), ENT_QUOTES, 'UTF-8');
            $html['roi'] = htmlentities(number_format($roi) . '%', ENT_QUOTES, 'UTF-8');
            $html['ppc_account_name'] = htmlentities($info_row2['ppc_account_name'], ENT_QUOTES, 'UTF-8');
            $html['aff_campaign_payout'] = htmlentities($info_row['aff_campaign_payout'], ENT_QUOTES, 'UTF-8');
            $ppc_network_icon = pcc_network_icon($info_row2['ppc_network_name'], $info_row2['ppc_account_name']);
            //shorten campaign name
            if (strlen($html['ppc_account_name']) > 20) {
                $html['ppc_account_name'] = substr($html['ppc_account_name'], 0, 20) . '...';
            }
            ?>
			   
				<tr>
					<td colspan="4" style="text-align:left; padding-left: 10px;"><?php 
            echo $ppc_network_icon;
            ?>
 - <?php 
            echo $html['ppc_account_name'];
            ?>
</td>
					<td><?php 
示例#2
0
 $html['ppc_network_name'] = htmlentities($click_row['ppc_network_name'], ENT_QUOTES, 'UTF-8');
 $html['ppc_account_name'] = htmlentities($click_row['ppc_account_name'], ENT_QUOTES, 'UTF-8');
 $html['ip_address'] = htmlentities($click_row['ip_address'], ENT_QUOTES, 'UTF-8');
 $html['click_cpc'] = htmlentities(dollar_format($click_row['click_cpc']), ENT_QUOTES, 'UTF-8');
 $html['keyword'] = htmlentities($click_row['keyword'], ENT_QUOTES, 'UTF-8');
 $html['click_lead'] = htmlentities($click_row['click_lead'], ENT_QUOTES, 'UTF-8');
 $html['click_filtered'] = htmlentities($click_row['click_filtered'], ENT_QUOTES, 'UTF-8');
 //rotate colors
 $html['row_class'] = 'item';
 if ($x == 0) {
     $html['row_class'] = 'item alt';
     $x = 1;
 } else {
     $x--;
 }
 $ppc_network_icon = pcc_network_icon($click_row['ppc_network_name'], $click_row['ppc_account_name']);
 if (geoLocationDatabaseInstalled() == true) {
     $html['location'] = '';
     if ($click_row['location_country_name']) {
         if ($click_row['location_country_name']) {
             $origin = $click_row['location_country_name'];
         }
         if ($click_row['location_region_code'] and !is_numeric($click_row['location_region_code'])) {
             $origin = $click_row['location_region_code'] . ', ' . $origin;
         }
         if ($click_row['location_city_name']) {
             $origin = $click_row['location_city_name'] . ', ' . $origin;
         }
         $html['origin'] = htmlentities($origin, ENT_QUOTES, 'UTF-8');
         $html['location'] = '<img title="' . $html['origin'] . '" src="http://' . $_SERVER['SERVER_NAME'] . '/xtracks-img/flags/' . strtolower($click_row['location_country_code']) . '.png"/>';
     }
示例#3
0
 $html['browser_name'] = htmlentities($click_row['browser_name'], ENT_QUOTES, 'UTF-8');
 $html['platform_name'] = htmlentities($click_row['platform_name'], ENT_QUOTES, 'UTF-8');
 $html['country_code'] = htmlentities($click_row['country_code'], ENT_QUOTES, 'UTF-8');
 $html['country_name'] = htmlentities($click_row['country_name'], ENT_QUOTES, 'UTF-8');
 $html['region_name'] = htmlentities($click_row['region_name'], ENT_QUOTES, 'UTF-8');
 $html['city_name'] = htmlentities($click_row['city_name'], ENT_QUOTES, 'UTF-8');
 $html['isp_name'] = htmlentities($click_row['isp_name'], ENT_QUOTES, 'UTF-8');
 //rotate colors
 $html['row_class'] = 'item';
 if ($x == 0) {
     $html['row_class'] = 'item alt';
     $x = 1;
 } else {
     $x--;
 }
 $ppc_network_icon = pcc_network_icon($click_row['ppc_network_name'], $click_row['ppc_account_name'], $html['referer_host']);
 if (!$click_row['type_name']) {
     $html['device_type'] = '<span id="device-tooltip"><span data-toggle="tooltip" title="Browser: ' . $html['browser_name'] . '<br/> Platform: ' . $html['platform_name'] . ' <br/>Device: ' . $html['device_name'] . '"><img title="' . $click_row['type_name'] . '" src="/202-img/icons/platforms/other.png"/></span></span>';
 } else {
     $html['device_type'] = '<span id="device-tooltip"><span data-toggle="tooltip" title="Browser: ' . $html['browser_name'] . '<br/> Platform: ' . $html['platform_name'] . ' <br/>Device: ' . $html['device_name'] . '"><img title="' . $click_row['type_name'] . '" src="/202-img/icons/platforms/' . $click_row['type_name'] . '.png"/></span></span> <img src="/202-img/icons/browsers/' . getBrowserIcon($html['browser_name']) . '.png">';
 }
 if (!$html['country_code']) {
     $html['country_code'] = 'non';
 }
 //if this is an advance landing page, make the offer name, the landing page name
 if ($click_row['click_alp'] == 1) {
     $html['aff_campaign_name'] = $html['landing_page_nickname'];
 }
 //before it ends, if this click is past 5 seconds, set true to $endofnewclicks
 $diff = time() - $click_row['click_time'];
 if ($diff > 5 and $new == true) {