// Get refs by userid
$cnt = RALLYE_GET_REFCOUNT($uid);
- if (empty($cnt)) $cnt = "0"; // Added prevent some unknown troubles... :-?
+ if (empty($cnt)) $cnt = 0; // Added prevent some unknown troubles... :-?
// Check if line is already included...
$result_ref = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_rallye_users WHERE rallye_id=%s AND userid=%s LIMIT 1",
list($refpoints) = SQL_FETCHROW($result_ref);
SQL_FREERESULT($result_ref);
- if (empty($refpoints)) $refpoints = "0";
+ if (empty($refpoints)) $refpoints = 0;
// And subtract start refs
$cnt -= $refs;
$DATA['now_t'] = MAKE_DATETIME(time(), "2");
$DATA['title'] = $title;
$DATA['id'] = $id; // ID for the rallye details link
- $DATA['ref'] = "0";
+ $DATA['ref'] = 0;
// Load prices
$prices = RALLYE_ADD_PRICES($id);
list($refpoints) = SQL_FETCHROW($result_ref);
SQL_FREERESULT($result_ref);
- if (empty($refpoints)) $refpoints = "0";
+ if (empty($refpoints)) $refpoints = 0;
// Store calculated new refs to array
$users['uid'][] = $uid;
SQL_FREERESULT($result_ref);
if (empty($cnt))
{
- $cnt = "0";
+ $cnt = 0;
}
else
{