From: hickert Date: Fri, 4 Aug 2006 09:23:02 +0000 (+0000) Subject: Added download button X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=2d0fd1033b5981348f6606e637c149e9346f3656;p=gosa.git Added download button git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@4391 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/admin/applications/class_applicationGeneric.inc b/plugins/admin/applications/class_applicationGeneric.inc index d58ac6e7c..92da9a56b 100644 --- a/plugins/admin/applications/class_applicationGeneric.inc +++ b/plugins/admin/applications/class_applicationGeneric.inc @@ -110,6 +110,18 @@ class application extends plugin $smarty= get_smarty(); + if(isset($_POST['download'])){ + header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); + header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + header("Cache-Control: no-cache"); + header("Pragma: no-cache"); + header("Cache-Control: post-check=0, pre-check=0"); + header("Content-type: application/octet-stream"); + header( "Content-disposition: attachment; filename=".$this->cn.".gotoLogonScript" ); + echo $this->gotoLogonScript; + exit(); + } + /* Do we represent a valid group? */ if (!$this->is_account && $this->parent == NULL){ $display= "\"\" ". diff --git a/plugins/admin/applications/generic.tpl b/plugins/admin/applications/generic.tpl index 4877a8802..c8a54ac1e 100644 --- a/plugins/admin/applications/generic.tpl +++ b/plugins/admin/applications/generic.tpl @@ -99,7 +99,8 @@

{t}Script{/t} {t}Script{/t}

- + +