Problem with one URL not in reload lock fixed
[mailer.git] / inc / functions.php
index 64ff243e2e37ca28910a18919b330e09dd9fd212..640ff9df0f317ec2310b2cfdb3b429cf48b0cd89 100644 (file)
@@ -33,7 +33,7 @@
 
 // Some security stuff...
 if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) {
 
 // Some security stuff...
 if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
 }
 
        require($INC);
 }
 
@@ -140,7 +140,7 @@ function OUTPUT_HTML($HTML, $NEW_LINE = true) {
                while (strpos($OUTPUT, '{!') > 0) {
                        // Prepare the content and eval() it...
                        $newContent = "";
                while (strpos($OUTPUT, '{!') > 0) {
                        // Prepare the content and eval() it...
                        $newContent = "";
-                       $eval = "\$newContent = \"" . COMPILE_CODE(addslashes($OUTPUT)) . "\";";
+                       $eval = "\$newContent = \"".COMPILE_CODE(addslashes($OUTPUT))."\";";
                        @eval($eval);
 
                        if (empty($newContent)) {
                        @eval($eval);
 
                        if (empty($newContent)) {
@@ -160,7 +160,7 @@ function OUTPUT_HTML($HTML, $NEW_LINE = true) {
 
                // Compile and run finished rendered HTML code
                while (strpos($OUTPUT, '{!') > 0) {
 
                // Compile and run finished rendered HTML code
                while (strpos($OUTPUT, '{!') > 0) {
-                       $eval = "\$OUTPUT = \"" . COMPILE_CODE(addslashes($OUTPUT)) . "\";";
+                       $eval = "\$OUTPUT = \"".COMPILE_CODE(addslashes($OUTPUT))."\";";
                        eval($eval);
                }
 
                        eval($eval);
                }
 
@@ -292,7 +292,7 @@ function LOAD_TEMPLATE($template, $return=false, $content="") {
                // 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!
-                       $tmpl_file = "\$ret=\"" . COMPILE_CODE(addslashes($tmpl_file)) . "\";";
+                       $tmpl_file = "\$ret=\"".COMPILE_CODE(addslashes($tmpl_file))."\";";
                        eval($tmpl_file);
                } else {
                        // Simply return loaded code
                        eval($tmpl_file);
                } else {
                        // Simply return loaded code
@@ -332,7 +332,7 @@ function LOAD_TEMPLATE($template, $return=false, $content="") {
 // 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.)
-       $eval = "\$SUBJECT = \"" . COMPILE_CODE(addslashes($SUBJECT)) . "\";";
+       $eval = "\$SUBJECT = \"".COMPILE_CODE(addslashes($SUBJECT))."\";";
        eval($eval);
        $SUBJECT = html_entity_decode($SUBJECT);
 
        eval($eval);
        $SUBJECT = html_entity_decode($SUBJECT);
 
@@ -939,6 +939,11 @@ function LOAD_URL($URL, $addUrlData=true) {
                OUTPUT_HTML("<A href=\"".$URL."\">".$URL."</A>");
        } elseif (!headers_sent()) {
                // Load URL when headers are not sent
                OUTPUT_HTML("<A href=\"".$URL."\">".$URL."</A>");
        } elseif (!headers_sent()) {
                // Load URL when headers are not sent
+               /*
+               print("<pre>");
+               debug_print_backtrace();
+               die("</pre>URL={$URL}");
+               */
                @header ("Location: ".str_replace("&amp;", "&", $URL));
        } else {
                // Output error message
                @header ("Location: ".str_replace("&amp;", "&", $URL));
        } else {
                // Output error message
@@ -1858,7 +1863,7 @@ function MEMBER_ACTION_LINKS($uid, $status="") {
        }
 
        // Finish navigation link
        }
 
        // Finish navigation link
-       $eval = substr($eval, 0, -7) . "]\";";
+       $eval = substr($eval, 0, -7)."]\";";
        eval($eval);
 
        // Return string
        eval($eval);
 
        // Return string
@@ -1942,7 +1947,7 @@ function generateHash ($plainText, $salt = "") {
        }
 
        // Return hash
        }
 
        // Return hash
-       return $salt . sha1($salt . $plainText);
+       return $salt.sha1($salt.$plainText);
 }
 //
 function scrambleString($str) {
 }
 //
 function scrambleString($str) {