Author:   Lars Michelsen <[email protected]>
Date:     Fri Dec 16 12:56:47 2011 +0100
Committer:   Lars Michelsen <[email protected]>
Commit-Date: Fri Dec 16 12:56:47 2011 +0100

Add the language to the target url when the user requested a specific language

---

 ChangeLog                                          |    1 +
 .../frontend/nagvis-js/classes/NagVisLoginView.php |    8 ++++++++
 2 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 2f4303c..45e4456 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -7,6 +7,7 @@ Frontend
   * Ajax call for redrawing map objects is not cacheable anymore (prevent 
strange
     hopping of icons after unlock -> edit -> lock in some cases.
   * Context menu: Small spacer row styling (preventing hover effect)
+  * Add the language to the target url when the user requested a specific 
language
 
 1.6
 Core
diff --git a/share/frontend/nagvis-js/classes/NagVisLoginView.php 
b/share/frontend/nagvis-js/classes/NagVisLoginView.php
index 4dc89fc..c8fee2a 100644
--- a/share/frontend/nagvis-js/classes/NagVisLoginView.php
+++ b/share/frontend/nagvis-js/classes/NagVisLoginView.php
@@ -57,6 +57,14 @@ class NagVisLoginView {
                          .'&show='.cfg('global', 'startshow');
         $target = CoreRequestHandler::getReferer($defaultTarget);
 
+        // Add the language to the target url when the user requested a 
specific language
+        if(isset($_GET['lang']) && strpos($target, 'lang=') === false) {
+            if(strpos($target, '?') === false)
+                $target .= '?lang='.$_GET['lang'];
+            else
+                $target .= '&lang='.$_GET['lang'];
+        }
+
         $aData = Array(
             'generalProperties' => 
$this->CORE->getMainCfg()->parseGeneralProperties(),
             'pageTitle' => cfg('internal', 'title') . ' &rsaquo; Log In',


------------------------------------------------------------------------------
Learn Windows Azure Live!  Tuesday, Dec 13, 2011
Microsoft is holding a special Learn Windows Azure training event for 
developers. It will provide a great way to learn Windows Azure and what it 
provides. You can attend the event by watching it streamed LIVE online.  
Learn more at http://p.sf.net/sfu/ms-windowsazure
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins

Reply via email to