Merging changes form main trunk 2.2.5-2.2.6
[fa-stable.git] / includes / main.inc
index e1b03fd2579a544fa544e0990d14adb87cd4cb20..3686aebea0dfc58a58833b37e728ee936fa07c96 100644 (file)
@@ -49,11 +49,14 @@ function page($title, $no_menu=false, $is_index=false, $onload="", $js="", $scri
 
 function end_page($no_menu=false, $is_index=false, $hide_back_link=false)
 {
-       global $path_to_root, $Ajax;
-       $hide_menu = $no_menu;
-               div_end();      // _page_body section
-       include($path_to_root . "/includes/page/footer.inc");
-       page_footer($no_menu, $is_index, $hide_back_link);
+       global $path_to_root;
+
+       if (!$is_index && !$hide_back_link && function_exists('hyperlink_back'))
+               hyperlink_back(true, $no_menu);
+       div_end();      // end of _page_body section
+
+       include($path_to_root . "/includes/page/footer.inc");
+       page_footer($no_menu, $is_index, $hide_back_link);
 }
 
 function flush_dir($path, $wipe = false)