summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 66b9893)
raw | patch | inline | side by side (parent: 66b9893)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 23 Jan 2008 09:42:53 +0000 (09:42 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 23 Jan 2008 09:42:53 +0000 (09:42 +0000) |
-Will no longer use getFAIscript.php.
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8554 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8554 594d385d-05f5-0310-b6e9-bd551577e9d8
diff --git a/gosa-plugins/fai/admin/fai/class_faiHook.inc b/gosa-plugins/fai/admin/fai/class_faiHook.inc
index fb64e5d3c56c4e18dc73e245477d5335459b6bcb..f1fec85fcca50681474f10bb2c4d8609f81ac458 100644 (file)
}
}
+ /* File download requested */
+ if(isset($_GET['getFAIHook'])){
+ if(isset($this->SubObjects[$_GET['getFAIHook']])){
+ $obj = $this->SubObjects[$_GET['getFAIHook']];
+ $obj = $this->get_object_attributes($obj,$this->sub_Load_Later);
+ send_binary_content($obj['FAIscript'],$obj['cn'].".FAIhook");
+ }
+ }
+
/* Edit entries via GET */
if(isset($_GET['act']) && isset($_GET['id'])){
if($_GET['act'] == "edit" && isset($this->SubObjects[$_GET['id']])){
if(($this->SubObjects[$key]['status'] == "new") || ($this->SubObjects[$key]['dn'] == "new") || !preg_match("/r/",$s_acl)){
$down = "";
}else{
- $down = "<a href='getFAIscript.php?id=".base64_encode($name['dn'])."'>
+ $down = "<a href='?plug=".$_GET['plug']."&getFAIHook=".$key."'>
<img src='images/save.png' alt='"._("Download")."' title='"._("Download")."' border=0>
</a>";
}
diff --git a/gosa-plugins/fai/admin/fai/class_faiHookEntry.inc b/gosa-plugins/fai/admin/fai/class_faiHookEntry.inc
index cab96dbf2074f8054f2ffa84e4f21846d80d21f3..282dbcf90c835378c9cdc72f7b6e8c98f40f081b 100644 (file)
}
}
+ /* File download requested */
+ if(isset($_GET['getFAIHook'])){
+ send_binary_content($this->FAIscript,$this->cn.".FAIhook");
+ }
+
/* Create download button*/
if($this->dn != "new" && $this->acl_is_readable("FAIscript")){
- $smarty->assign("DownMe","<a href='getFAIscript.php?id=".base64_encode($this->dn)."'>
+ $smarty->assign("DownMe","<a href='?plug=".$_GET['plug']."&getFAIHook'>
<img src='images/save.png' alt='"._("Download")."' title='"._("Download")."' border=0 class='center'>
</a>");
}else{
diff --git a/gosa-plugins/fai/admin/fai/class_faiScript.inc b/gosa-plugins/fai/admin/fai/class_faiScript.inc
index 2233b6ae6c6ca8ec9808a75ca040d5150bb9fdb2..d47ed33c3decee0e89045fea91066c6086163f9d 100644 (file)
session::set('objectinfo',$this->dn);
}
+ /* File download requested */
+ if(isset($_GET['getFAIscript'])){
+ if(isset($this->SubObjects[$_GET['getFAIscript']])){
+ $obj = $this->SubObjects[$_GET['getFAIscript']];
+ $obj = $this->get_object_attributes($obj,$this->sub_Load_Later);
+ send_binary_content($obj['FAIscript'],$obj['cn'].".FAIscript");
+ }
+ }
+
/* Handle posts */
$s_action = $s_entry = "";
foreach($_POST as $name => $value){
if(($this->SubObjects[$key]['status'] == "new") || ($this->SubObjects[$key]['dn'] == "new") || !preg_match("/r/",$s_acl)){
$down = "";
}else{
- $down = "<a href='getFAIscript.php?id=".base64_encode($name['dn'])."' >
+ $down = "<a href='?plug=".$_GET['plug']."&getFAIscript=".$key."'>
<img src='images/save.png' alt='"._("Download")."' title='"._("Download")."' border=0>
</a>";
}
diff --git a/gosa-plugins/fai/admin/fai/class_faiScriptEntry.inc b/gosa-plugins/fai/admin/fai/class_faiScriptEntry.inc
index 0321329209825ddaac037fff565a47c70348d085..ab3b589f1276da25447b4ca69a020dffc4950612 100644 (file)
}
}
- /* Create download button*/
+ /* File download requested */
+ if(isset($_GET['getFAIScript'])){
+ send_binary_content($this->FAIscript,$this->cn.".FAIscript");
+ }
+
+ /* Create download button*/
if($this->dn != "new" && $this->acl_is_readable("FAIscript")){
- $smarty->assign("DownMe","<a href='getFAIscript.php?id=".base64_encode($this->dn)."'>
- <input type='button' value='"._("Download")."'>
+ $smarty->assign("DownMe","<a href='?plug=".$_GET['plug']."&getFAIScript'>
+ <img src='images/save.png' alt='"._("Download")."' title='"._("Download")."' border=0 class='center'>
</a>");
}else{
$smarty->assign("DownMe","");
diff --git a/gosa-plugins/fai/admin/fai/class_faiTemplate.inc b/gosa-plugins/fai/admin/fai/class_faiTemplate.inc
index 54bd8326728984c69c5e1cc89dc396f02a1301cd..50add1a379a38ff3f827b56b257fcea2095e7979 100644 (file)
}
}
+ /* File download requested */
+ if(isset($_GET['getFAItemplate'])){
+ if(isset($this->SubObjects[$_GET['getFAItemplate']])){
+ $obj = $this->SubObjects[$_GET['getFAItemplate']];
+ $obj = $this->get_object_attributes($obj,$this->sub_Load_Later);
+ send_binary_content($obj['FAItemplateFile'],$obj['cn'].".FAItemplate");
+ }
+ }
+
/* Edit entries via GET */
if(isset($_GET['act']) && isset($_GET['id'])){
if($_GET['act'] == "edit" && isset($this->SubObjects[$_GET['id']])){
if(($this->SubObjects[$key]['status'] == "new") || ($this->SubObjects[$key]['dn'] == "new") || !preg_match("/r/",$s_acl)){
$down = "";
}else{
- $down = "<a href='getFAIscript.php?is_template&id=".base64_encode($dn)."'>
+ $down = "<a href='?plug=".$_GET['plug']."&getFAItemplate=".$key."'>
<img src='images/save.png' alt='"._("Download")."' title='"._("Download")."' border=0>
</a>";
}