]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/guest/what-mediadata.php
Updated copyright year.
[mailer.git] / inc / modules / guest / what-mediadata.php
index 7bb56305bc18b23d75e8d439b51ca915c5d56bfb..605c2d12fd682b39fb5a49c3c4176457f831eeb5 100644 (file)
  * -------------------------------------------------------------------- *
  * Kurzbeschreibung  : Mediendaten                                      *
  * -------------------------------------------------------------------- *
- * $Revision::                                                        $ *
- * $Date::                                                            $ *
- * $Tag:: 0.2.1-FINAL                                                 $ *
- * $Author::                                                          $ *
- * -------------------------------------------------------------------- *
  * Copyright (c) 2003 - 2009 by Roland Haeder                           *
- * Copyright (c) 2009 - 2013 by Mailer Developer Team                   *
+ * Copyright (c) 2009 - 2016 by Mailer Developer Team                   *
  * For more information visit: http://mxchange.org                      *
  *                                                                      *
  * This program is free software; you can redistribute it and/or modify *
@@ -126,17 +121,12 @@ $content['sent']       = $sent;
 $content['user_links'] = abs($sent - $clicks);
 
 // Click rate
-$content['click_rate'] = '0';
-if ($sent > 0) {
-       $content['click_rate'] = $clicks / $sent * 100;
-} // END - if
+$content['click_rate'] = calculatePercentageRate($clicks, $sent);
 
 // Load jackpot
-$jackpot = '0';
-if (isExtensionActive('jackpot')) $jackpot = getJackpotPoints();
-
-if (empty($jackpot)) $jackpot = '0';
-$content['jackpot'] = $jackpot;
+$content['jackpot'] = '0';
+if (isExtensionActive('jackpot')) $content['jackpot'] = getJackpotPoints();
+if (empty($content['jackpot'])) $content['jackpot'] = '0';
 
 // Total referral link clicks, total logins
 $result = sqlQuery('SELECT
@@ -190,7 +180,7 @@ if (isExtensionActive('beg')) {
        // Clicks on beg links
        $data = array(
                'lang'  => '{--MEDIA_BEG_CLICKS--}',
-               'value' => countSumTotalData('0', 'user_data', 'beg_clicks', 'userid', FALSE, ' AND `beg_clicks` > 0')
+               'value' => countSumTotalData('0', 'user_data', 'beg_clicks', 'userid', FALSE, ' WHERE `beg_clicks` > 0')
        );
        $OUT_EXTRA .= loadTemplate('mediadata_extra_row', TRUE, $data);
 } // END - if