Fix problem with javascript when user has other plugins that include a
[squirrelmail.git] / plugins / message_details / message_details_bottom.php
index 6520a0963997ebee1c203ec33afe5129138ca39f..83c33df981a6152cab5e4fa624eff0f91d160540 100644 (file)
@@ -21,18 +21,25 @@ require_once(SM_PATH . 'functions/prefs.php');
 
 global $color, $uid_support;
 
+sqgetGlobalVar('passed_id', $passed_id, SQ_GET);
+sqgetGlobalVar('mailbox', $mailbox, SQ_GET);
+
+sqgetGlobalVar('username', $username, SQ_SESSION);
+sqgetGlobalVar('key', $key, SQ_COOKIE);
+sqgetGlobalVar('onetimepad', $onetimepad, SQ_SESSION);
+
 function CalcEntity($entString, $direction) {
     $result = $entString;
     if ($direction == -1) {
-         $pos = strrpos($entString,'.');
-         $result = substr($entString,0,$pos);
+        $pos = strrpos($entString,'.');
+        $result = substr($entString,0,$pos);
     }
 
     switch ($direction) {
        case 0:
           $pos = strrpos($entString,'.');
           if ($pos === false) {
-            $entString++;
+         $entString++;
             $result= $entString;
           } 
          else {
@@ -300,11 +307,11 @@ if (count($content) > 0) {
        echo '</td><td>';
        if (isset($content[$i]['name'])) {
            echo $content[$i]['name'];
-       } else echo '&nbsp';
+       } else echo '&nbsp;';
        echo '</td><td>';
        if (isset($content[$i]['encoding'])) {
            echo $content[$i]['encoding'];
-       } else echo '&nbsp';
+       } else echo '&nbsp;';
        echo '</td></tr>'."\n";
     }
     echo '</tbody></table><br>'."\n";