From 3a2b270c9d1f531c2e2d1c422a4756afd639ef47 Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Mon, 15 Jun 2009 03:01:36 -0400
Subject: [PATCH] - always call logout action as task (#1485919)

---
 program/include/rcube_template.php |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/program/include/rcube_template.php b/program/include/rcube_template.php
index c6d75dd..455bbcf 100755
--- a/program/include/rcube_template.php
+++ b/program/include/rcube_template.php
@@ -435,6 +435,7 @@
      */
     private function parse_with_globals($input)
     {
+        $GLOBALS['__version'] = Q(RCMAIL_VERSION);
         $GLOBALS['__comm_path'] = Q($this->app->comm_path);
         return preg_replace('/\$(__[a-z0-9_\-]+)/e', '$GLOBALS["\\1"]', $input);
     }
@@ -968,7 +969,7 @@
         
         // save original url
         $url = get_input_value('_url', RCUBE_INPUT_POST);
-        if (empty($url) && !preg_match('/_action=logout/', $_SERVER['QUERY_STRING']))
+        if (empty($url) && !preg_match('/_(task|action)=logout/', $_SERVER['QUERY_STRING']))
             $url = $_SERVER['QUERY_STRING'];
 
         $input_user   = new html_inputfield(array('name' => '_user', 'id' => 'rcmloginuser', 'size' => 30) + $attrib);

--
Gitblit v1.9.1