Remove unused graphics file.
[squirrelmail.git] / src / right_main.php
index 33126f19d4d63d7bff8263e868c805e20d7635a8..c65a4c206e55fe6957b64bdb29acf7567014e40c 100644 (file)
  * $Id$
  */
 
-require_once('../src/validate.php');
-require_once('../functions/imap.php');
-require_once('../functions/date.php');
-require_once('../functions/array.php');
-require_once('../functions/mime.php');
-require_once('../functions/mailbox_display.php');
-require_once('../functions/display_messages.php');
-require_once('../functions/html.php');
+/* Path for SquirrelMail required files. */
+define('SM_PATH','../');
+
+/* SquirrelMail required files. */
+require_once(SM_PATH . 'include/validate.php');
+require_once(SM_PATH . 'functions/imap.php');
+require_once(SM_PATH . 'functions/date.php');
+require_once(SM_PATH . 'functions/array.php');
+require_once(SM_PATH . 'functions/mime.php');
+require_once(SM_PATH . 'functions/mailbox_display.php');
+require_once(SM_PATH . 'functions/display_messages.php');
+require_once(SM_PATH . 'functions/html.php');
 
 /***********************************************************
  * incoming variables from URL:                            *
@@ -34,8 +38,6 @@ require_once('../functions/html.php');
  *    $key              pass                               *
  ***********************************************************/
 
-$bob = getHashedFile($username, $data_dir, "username.pref");
-
 /* Open a connection on the imap port (143) */
 
 $imapConnection = sqimap_login($username, $key, $imapServerAddress, $imapPort, 0);
@@ -102,22 +104,18 @@ else {
 } 
 
 global $color;
-if( isset($do_hook) && $do_hook ) {
-    do_hook ("generic_header");
-}
+
+do_hook ("generic_header");
 
 sqimap_mailbox_select($imapConnection, $mailbox);
 
 if (isset($composenew) && $composenew) {
     $comp_uri = "../src/compose.php?mailbox=". urlencode($mailbox).
-               "&session=$composesession&attachedmessages=true&amp";
-
-    displayPageHeader($color, $mailbox, "comp_in_new(false,'$comp_uri');", false);
+               "&session=$composesession";
+    displayPageHeader($color, $mailbox, "comp_in_new('$comp_uri');", false);
 } else {
     displayPageHeader($color, $mailbox);
 }
-echo "<br>\n";
-
 do_hook('right_main_after_header');
 if (isset($note)) {
     echo html_tag( 'div', '<b>' . $note .'</b>', 'center' ) . "<br>\n";
@@ -129,7 +127,7 @@ if ($just_logged_in == true) {
     if (strlen(trim($motd)) > 0) {
         echo html_tag( 'table',
                     html_tag( 'tr',
-                        html_tag( 'td', $motd ,
+                        html_tag( 'td', 
                             html_tag( 'table',
                                 html_tag( 'tr',
                                     html_tag( 'td', $motd, 'center' )
@@ -202,4 +200,4 @@ sqimap_logout ($imapConnection);
 
 echo '</body></html>';
 
-?>
\ No newline at end of file
+?>