SQL_FREERESULT($result_rec);
// Initial lots of variables
-$bmails = "0"; $sent = "0"; $max = "0"; $rec = "0"; $clicks = "0";
+$bmails = 0; $sent = 0; $max = 0; $rec = 0; $clicks = 0;
// Mail orders (only current)
$nmails = MEDIA_GET_ENTRY("normal_orders");
-if (empty($nmails)) $nmails = "0";
+if (empty($nmails)) $nmails = 0;
// Mails sent so far
$clicks = MEDIA_GET_ENTRY("normal_clicks");
$sent = MEDIA_GET_ENTRY("normal_send");
-if (empty($sent)) $sent = "0";
-if (empty($clicks)) $clicks = "0";
+if (empty($sent)) $sent = 0;
+if (empty($clicks)) $clicks = 0;
// Bonus mails
if (EXT_IS_ACTIVE("bonus")) {
$bmails = MEDIA_GET_ENTRY("bonus_orders");
- if (empty($bmails)) $bmails = "0";
+ if (empty($bmails)) $bmails = 0;
// Count bonus mails clicks / sent mails
$dmy = MEDIA_GET_ENTRY("bonus_clicks");
$dmy2 = MEDIA_GET_ENTRY("bonus_send");
- if (empty($dmy)) $dmy = "0";
- if (empty($dmy2)) $dmy2 = "0";
+ if (empty($dmy)) $dmy = 0;
+ if (empty($dmy2)) $dmy2 = 0;
$sent += $dmy2; $clicks += $dmy;
}
$result = SQL_QUERY("SELECT points FROM "._MYSQL_PREFIX."_jackpot WHERE ok='ok' LIMIT 1", __FILE__, __LINE__);
list($jackpot) = SQL_FETCHROW($result);
SQL_FREERESULT($result);
-if (empty($jackpot)) $jackpot = "0";
+if (empty($jackpot)) $jackpot = 0;
define('jackpot', TRANSLATE_COMMA($jackpot));
// Total referral link clicks, total logins
// Get total points
$points = MEDIA_GET_ENTRY("total_points");
-if (empty($points)) $points = "0";
-if (empty($ref)) $ref = "0";
-if (empty($logins)) $logins = "0";
+if (empty($points)) $points = 0;
+if (empty($ref)) $ref = 0;
+if (empty($logins)) $logins = 0;
define('__TOTAL_POINTS' , TRANSLATE_COMMA($points));
define('__TOTAL_REFCLICKS', $ref);
list($views, $clicks) = SQL_FETCHROW($result);
SQL_FREERESULT($result);
-if (empty($total)) $total = "0";
-if (empty($views)) $views = "0";
-if (empty($clicks)) $clicks = "0";
+if (empty($total)) $total = 0;
+if (empty($views)) $views = 0;
+if (empty($clicks)) $clicks = 0;
define('__REF_TOTAL' , $total);
define('__REF_VIEWS' , $views);
$result = SQL_QUERY("SELECT SUM(beg_clicks) FROM "._MYSQL_PREFIX."_user_data WHERE beg_clicks>0", __FILE__, __LINE__);
list($extra) = SQL_FETCHROW($result);
SQL_FREERESULT($result);
- if (empty($extra)) $extra = "0";
+ if (empty($extra)) $extra = 0;
$content = array(
'lang' => MEDIA_BEG_CLICKS,
'value' => $extra
list($count2, $points2) = SQL_FETCHROW($result);
SQL_FREERESULT($result);
- if (empty($count1)) $count1 = "0";
- if (empty($count2)) $count2 = "0";
- if (empty($points1)) $points1 = "0";
- if (empty($points2)) $points2 = "0";
+ if (empty($count1)) $count1 = 0;
+ if (empty($count2)) $count2 = 0;
+ if (empty($points1)) $points1 = 0;
+ if (empty($points2)) $points2 = 0;
// Add header
$OUT_SPECIAL .= LOAD_TEMPLATE("mediadata_extra_hrow", true, MEDIA_DOUBLER_HEADER);
WHERE d.holiday_active='Y'",
__FILE__, __LINE__);
list($holiday) = SQL_FETCHROW($result);
- if (empty($holiday)) $holiday = "0";
+ if (empty($holiday)) $holiday = 0;
$content = array(
'lang' => MEDIA_HOLIDAY_COUNT,
'value' => $holiday
ON t.userid=d.userid",
__FILE__, __LINE__);
list($count_in, $points_in) = SQL_FETCHROW($result);
- if (empty($count_in)) $count_in = "0";
- if (empty($points_in)) $points_in = "0";
+ if (empty($count_in)) $count_in = 0;
+ if (empty($points_in)) $points_in = 0;
$result = SQL_QUERY("SELECT DISTINCT COUNT(t.id), SUM(t.points)
FROM "._MYSQL_PREFIX."_user_transfers_out AS t
ON t.userid=d.userid",
__FILE__, __LINE__);
list($count_out, $points_out) = SQL_FETCHROW($result);
- if (empty($count_out)) $count_out = "0";
- if (empty($points_out)) $points_out = "0";
+ if (empty($count_out)) $count_out = 0;
+ if (empty($points_out)) $points_out = 0;
// Add header
$OUT_SPECIAL .= LOAD_TEMPLATE("mediadata_extra_hrow", true, MEDIA_TRANSFER_HEADER);