예제 #1
0
 static function admin_page_bottom($theme)
 {
     $session = Session::instance();
     if ($session->get("profiler", false)) {
         $profiler = new Profiler();
         $profiler->render();
     }
     if ($session->get("l10n_mode", false)) {
         return L10n_Client_Controller::l10n_form();
     }
 }
예제 #2
0
 static function admin_page_bottom($theme)
 {
     $session = Session::instance();
     if ($session->get("profiler", false)) {
         Profiler::enable();
         $profiler = new Profiler();
         $profiler->render();
     }
     // Redirect to the root album when the admin session expires.
     $content = '<script type="text/javascript">
   var adminReauthCheck = function() {
     $.ajax({url: "' . url::site("admin?reauth_check=1") . '",
             dataType: "json",
             success: function(data){
               if ("location" in data) {
                 document.location = data.location;
               }
             }});
   };
   setInterval("adminReauthCheck();", 60 * 1000);
   </script>';
     if (upgrade_checker::should_auto_check()) {
         $content .= '<script type="text/javascript">
     $.ajax({url: "' . url::site("admin/upgrade_checker/check_now?csrf=" . access::csrf_token()) . '"});
     </script>';
     }
     if ($session->get("l10n_mode", false)) {
         $content .= "\n" . L10n_Client_Controller::l10n_form();
     }
     return $content;
 }
예제 #3
0
 static function admin_page_bottom($theme)
 {
     $session = Session::instance();
     if ($session->get("profiler", false)) {
         Profiler::enable();
         $profiler = new Profiler();
         $profiler->render();
     }
     // Redirect to the root album when the admin session expires.
     $admin_session_redirect_check = '<script type="text/javascript">
   var adminReauthCheck = function() {
     $.ajax({url: "' . url::site("admin?reauth_check=1") . '",
             dataType: "json",
             success: function(data){
               if ("location" in data) {
                 document.location = data.location;
               }
             }});
   };
   setInterval("adminReauthCheck();", 60 * 1000);
   </script>';
     print $admin_session_redirect_check;
     if ($session->get("l10n_mode", false)) {
         return L10n_Client_Controller::l10n_form();
     }
 }