From fe5650e144177496b1ef8dc31a06e488e7adf35d Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Tue, 26 Nov 2013 15:55:56 +0000 Subject: [PATCH] Auto-detect location target if not set. Fixes whole page reloads in jdots/pixelegg. --- etemplate/inc/class.etemplate_widget_nextmatch.inc.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/etemplate/inc/class.etemplate_widget_nextmatch.inc.php b/etemplate/inc/class.etemplate_widget_nextmatch.inc.php index f887344f0d..29d7be5eea 100644 --- a/etemplate/inc/class.etemplate_widget_nextmatch.inc.php +++ b/etemplate/inc/class.etemplate_widget_nextmatch.inc.php @@ -694,6 +694,13 @@ class etemplate_widget_nextmatch extends etemplate_widget else { $action['data']['nm_action'] = 'location'; + if(!$action['target'] && strpos($action['url'],'menuaction') > 0) + { + // It would be better if app set target, but we'll auto-detect if not + list(,$menuaction) = explode('=',$action['url']); + list($app) = explode('.',$menuaction); + $action['data']['target'] = $app; + } } } if ($action['egw_open'])