From: janw Date: Fri, 10 Jun 2005 09:57:24 +0000 (+0000) Subject: Added popup function X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=b48dacd1e9570143b77633765e6cd2486fe720db;p=gosa.git Added popup function git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@655 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/html/include/focus.js b/html/include/focus.js index 978939c84..74ac8ceac 100644 --- a/html/include/focus.js +++ b/html/include/focus.js @@ -97,3 +97,13 @@ function toggle(element) { } +function popup(target, name) { + var mypopup= + window.open( + target, + name, + "width=600,height=700,location=no,toolbar=no,directories=no,menubar=no,status=no,scrollbars=yes" + ); + mypopup.focus(); + return false; +} diff --git a/html/main.php b/html/main.php index d04ede3b7..40222d053 100644 --- a/html/main.php +++ b/html/main.php @@ -212,8 +212,9 @@ if ($_SESSION['js']==FALSE){ $smarty->assign("help_method", "href='helpviewer.php$plug' target='_new'"); } else { $smarty->assign("javascript", "true"); - $smarty->assign("help_method", "href='' onClick=\"window.open('helpviewer.php$plug','{t}GOsa help{/t}','width=600,height=700,location=no,toolbar=no,directories=no,menubar=no,status=no,scrollbars=yes')\""); + $smarty->assign("help_method","href='' onclick=\"return popup('helpviewer.php$plug')\",'GOsa help')\""); } + $smarty->assign ("username", $ui->username); $smarty->assign ("go_logo", get_template_path('images/go_logo.png')); $smarty->assign ("go_base", get_template_path('images/dtree.png'));