$tmpl_file = implode("", file($file));
// Replace ' to our own chars to preventing them being quoted
$tmpl_file = implode("", file($file));
// Replace ' to our own chars to preventing them being quoted
- while (strpos($tmpl_file, "\'") !== false) { $tmpl_file = str_replace("\'", "{QUOT}", $tmpl_file); }
+ while (strpos($tmpl_file, "\'") !== false) { $tmpl_file = str_replace("\'", '{QUOT}', $tmpl_file); }
// Do we have to compile the code?
if ((strpos($tmpl_file, "\$") !== false) || (strpos($tmpl_file, '{--') !== false) || (strpos($tmpl_file, '--}') > 0)) {
// Okay, compile it!
// Do we have to compile the code?
if ((strpos($tmpl_file, "\$") !== false) || (strpos($tmpl_file, '{--') !== false) || (strpos($tmpl_file, '--}') > 0)) {
// Okay, compile it!
// Send mail out to an email address
function SEND_EMAIL($TO, $SUBJECT, $MSG, $HTML='N', $FROM="") {
// Compile subject line (for POINTS constant etc.)
// Send mail out to an email address
function SEND_EMAIL($TO, $SUBJECT, $MSG, $HTML='N', $FROM="") {
// Compile subject line (for POINTS constant etc.)
} elseif (!isSessionVariableSet('mx_lang')) {
// Return stored value from cookie
$ret = get_session('mx_lang');
} elseif (!isSessionVariableSet('mx_lang')) {
// Return stored value from cookie
$ret = get_session('mx_lang');
global $DATA, $_CONFIG, $REPLACER;
// Keept for backward-compatiblity (please replace these variables against our new {--CONST--} syntax!)
global $DATA, $_CONFIG, $REPLACER;
// Keept for backward-compatiblity (please replace these variables against our new {--CONST--} syntax!)
// Load nickname
$result = SQL_QUERY_ESC("SELECT surname, family, sex, email, nickname FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",
array(bigintval($UID)), __FILE__, __LINE__);
list($surname, $family, $sex, $email, $nick) = SQL_FETCHROW($result);
SQL_FREERESULT($result);
// Load nickname
$result = SQL_QUERY_ESC("SELECT surname, family, sex, email, nickname FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",
array(bigintval($UID)), __FILE__, __LINE__);
list($surname, $family, $sex, $email, $nick) = SQL_FETCHROW($result);
SQL_FREERESULT($result);
// Load normal data
$result = SQL_QUERY_ESC("SELECT surname, family, sex, email FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",
array(bigintval($UID)), __FILE__, __LINE__);
// Load normal data
$result = SQL_QUERY_ESC("SELECT surname, family, sex, email FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",
array(bigintval($UID)), __FILE__, __LINE__);
// Test for extension
$test = substr($template, 0, strpos($template, "_"));
// Test for extension
$test = substr($template, 0, strpos($template, "_"));
- $code = str_replace("{--", '".', str_replace("--}", '."', $code));
+ $code = str_replace('{--', '".', str_replace('--}', '."', $code));
- $code = str_replace("{!", '".', str_replace("!}", '."', $code));
+ $code = str_replace('{!', '".', str_replace("!}", '."', $code));
// Find $content[bla][blub] entries
@preg_match_all('/\$(content|DATA)((\[([a-zA-Z0-9-_]+)\])*)/', $code, $matches);
// Find $content[bla][blub] entries
@preg_match_all('/\$(content|DATA)((\[([a-zA-Z0-9-_]+)\])*)/', $code, $matches);
$OUT .= " <OPTION value=\"Y\"";
if ($DEFAULT == 'Y') $OUT .= " selected=\"selected\"";
$OUT .= ">".YES."</OPTION>
$OUT .= " <OPTION value=\"Y\"";
if ($DEFAULT == 'Y') $OUT .= " selected=\"selected\"";
$OUT .= ">".YES."</OPTION>
- $return = substr(str_replace('.', '', $rcode), 0, $len);
+ $return = substr(str_replace('.', "", $rcode), 0, $len);
// Open connection
$fp = @fsockopen($host, 80, $errno, $errdesc, 30);
// Open connection
$fp = @fsockopen($host, 80, $errno, $errdesc, 30);
if ((!empty($_GET['refid'])) && (strpos($URL, "refid=") == 0)) {
// Cookie found in URL
$ADD .= $BIND."refid=".bigintval($_GET['refid']);
if ((!empty($_GET['refid'])) && (strpos($URL, "refid=") == 0)) {
// Cookie found in URL
$ADD .= $BIND."refid=".bigintval($_GET['refid']);