Problem with one URL not in reload lock fixed
[mailer.git] / inc / functions.php
index aae3aae26a9139227769be974d76e7c08af2fdd2..640ff9df0f317ec2310b2cfdb3b429cf48b0cd89 100644 (file)
@@ -33,7 +33,7 @@
 
 // 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);
 }
 
@@ -140,7 +140,7 @@ function OUTPUT_HTML($HTML, $NEW_LINE = true) {
                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)) {
@@ -160,7 +160,7 @@ function OUTPUT_HTML($HTML, $NEW_LINE = true) {
 
                // 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);
                }
 
@@ -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!
-                       $tmpl_file = "\$ret=\"" . COMPILE_CODE(addslashes($tmpl_file)) . "\";";
+                       $tmpl_file = "\$ret=\"".COMPILE_CODE(addslashes($tmpl_file))."\";";
                        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.)
-       $eval = "\$SUBJECT = \"" . COMPILE_CODE(addslashes($SUBJECT)) . "\";";
+       $eval = "\$SUBJECT = \"".COMPILE_CODE(addslashes($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
+               /*
+               print("<pre>");
+               debug_print_backtrace();
+               die("</pre>URL={$URL}");
+               */
                @header ("Location: ".str_replace("&amp;", "&", $URL));
        } else {
                // Output error message
@@ -1378,7 +1383,7 @@ function CREATE_TIME_SELECTIONS($timestamp, $prefix="", $display="", $align="cen
                }
                if (ereg("s", $display) || (empty($display)))
                {
-                       $OUT .= "  <TD align=\"center\" class=\"admin_title bottom\"><STRONG class=\"tiny\">".SECS."</STRONG></TD>\n";
+                       $OUT .= "  <TD align=\"center\" class=\"admin_title bottom\"><STRONG class=\"tiny\">"._SECONDS."</STRONG></TD>\n";
                }
                $OUT .= "</TR>\n";
                $OUT .= "<TR>\n";
@@ -1858,7 +1863,7 @@ function MEMBER_ACTION_LINKS($uid, $status="") {
        }
 
        // Finish navigation link
-       $eval = substr($eval, 0, -7) . "]\";";
+       $eval = substr($eval, 0, -7)."]\";";
        eval($eval);
 
        // Return string
@@ -1942,7 +1947,7 @@ function generateHash ($plainText, $salt = "") {
        }
 
        // Return hash
-       return $salt . sha1($salt . $plainText);
+       return $salt.sha1($salt.$plainText);
 }
 //
 function scrambleString($str) {