- SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_rallye_users` (rallye_id, userid, refs)
-VALUES ('%s','%s','0')",
- array(bigintval($id), bigintval($uid)), __FUNCTION__, __LINE__);
- } else {
- // Free memory
- SQL_FREERESULT($result);
- }
-
- if ($notify == "Y") {
- // Transfer all neccessary data to the global $DATA array
- $DATA['start'] = MAKE_DATETIME($start, "2");
- $DATA['end'] = MAKE_DATETIME($end , "2");
- $DATA['now_t'] = MAKE_DATETIME(time(), "2");
- $DATA['title'] = $title;
- $DATA['id'] = $id; // ID for the rallye details link
- $DATA['ref'] = 0;
- $DATA['refs'] = GET_TOTAL_DATA($uid, "user_data", "userid", "refid", true);
-
- // Load prices
- $prices = RALLYE_ADD_PRICES($id);
-
- // Determine min_users/prices tring
- $DATA['min_users'] = RALLYE_DETERMINE_MIN_USERS($min_users);
- $DATA['min_prices'] = RALLYE_DETERMINE_MIN_PRICES($min_prices);
-
- // Send notification to member
- $msg = LOAD_EMAIL_TEMPLATE("member_rallye_notify", array('prices' => $prices), $uid);
- SEND_EMAIL($uid, sprintf(getMessage('RALLYE_MEMBER_NOTIFY'), $title), $msg);
+ SQL_QUERY_ESC("INSERT INTO
+ `{?_MYSQL_PREFIX?}_rallye_users`
+(
+ `rallye_id`,
+ `userid`,
+ `refs`
+) VALUES (
+ %s,
+ %s,
+ 0
+)",
+ array(
+ bigintval($content['id']),
+ bigintval($userid)
+ ), __FUNCTION__, __LINE__);