- Security: Possible cookie theft in src/redirect.php if
[squirrelmail.git] / src / search.php
index 4a2c836970205f2e64249ea1bde540b13203adb8..8e08124e4a9bed06558af31a0e63c2f817457e73 100644 (file)
@@ -24,7 +24,7 @@ define('SM_PATH','../');
 
 /** SquirrelMail required files.
  */
-require_once(SM_PATH . 'include/validate.php');
+include_once(SM_PATH . 'include/validate.php');
 include_once(SM_PATH . 'functions/strings.php');
 include_once(SM_PATH . 'functions/imap_asearch.php');
 include_once(SM_PATH . 'functions/imap_mailbox.php');
@@ -1013,8 +1013,8 @@ $aMailboxGlobalPref = array(
  * system wide admin settings and incoming vars.
  */
 $aConfig = array(
-                'allow_thread_sort' => $allow_thread_sort,
-                'allow_server_sort' => $allow_server_sort,
+//                'allow_thread_sort' => $allow_thread_sort,
+//                'allow_server_sort' => $allow_server_sort,
                 'user'              => $username,
                 'setindex'          => 1
                 );
@@ -1602,13 +1602,13 @@ if ($submit == $search_button_text) {
                         foreach ($aTemplate as $k => $v) {
                             $oTemplate->assign($k, $v);
                         }
+
                         $oTemplate->assign('page_selector',  $page_selector);
                         $oTemplate->assign('page_selector_max', $page_selector_max);
                         $oTemplate->assign('compact_paginator', $compact_paginator);
                         $oTemplate->assign('javascript_on', $javascript_on);
                         $oTemplate->assign('enablesort', (isset($aProps['config']['enablesort'])) ? $aProps['config']['enablesort'] : false);
-                        // Aaaaaahhhhhhh FIX ME DO NOT USE the string "none" for a var when you mean the boolean false or null
-                        $oTemplate->assign('icon_theme', (isset($icon_theme) && $icon_theme !== 'none') ? $icon_theme : false);
+                        $oTemplate->assign('icon_theme_path', $icon_theme_path);
                         $oTemplate->assign('use_icons', (isset($use_icons)) ? $use_icons : false);
                         $oTemplate->assign('aOrder', array_keys($aColumns));
                         $oTemplate->assign('alt_index_colors', isset($alt_index_colors) ? $alt_index_colors: false);
@@ -1641,7 +1641,7 @@ if ($submit == $search_button_text) {
 
 do_hook('search_bottom');
 sqimap_logout($imapConnection);
-echo '</body></html>';
+$oTemplate->display('footer.tpl');
 sqsession_register($mailbox_cache,'mailbox_cache');
 
 ?>