True, "nonavbar" => True, "currentapp" => "home", "noapi" => True);
include("./inc/functions.inc.php");
include("../version.inc.php");
/* authentication phase */
$phpgw_info["setup"]["stage"]["header"] = $phpgw_setup->check_header();
if ( $phpgw_info["setup"]["stage"]["header"] == 2){
$phpgw_setup->show_header("Please set your header admin password",True);
}elseif ( $phpgw_info["setup"]["stage"]["header"] == 10){
if (!$phpgw_setup->auth("Config")){
$phpgw_setup->show_header("Please login",True);
$phpgw_setup->login_form();
exit;
}else{ /* authentication settled. Moving to the database portion. */
$phpgw_setup->loaddb();
}
}
$phpgw_setup->check_header();
if ( $phpgw_info["setup"]["stage"] >= 1.4){
if (!$phpgw_setup->header_auth()){
$phpgw_setup->show_header("Please login",True);
$phpgw_setup->loginForm($login_msg);
exit;
}else{ /* authentication settled. Moving to the database portion. */
$phpgw_setup->loaddb();
}
}else{
$phpgw_setup->show_header("Please login",True);
$phpgw_setup->loginForm($login_msg);
exit;
}
switch($action){
case "download":
header("Content-disposition: attachment; filename=\"header.inc.php\"");
header("Content-type: application/octet-stream");
header("Pragma: no-cache");
header("Expires: 0");
$newheader = $phpgw_setup->generate_header();
echo $newheader;
break;
case "view":
$phpgw_setup->show_header("Generated header.inc.php");
echo "
Save this text as contents of your header.inc.php
"; echo htmlentities($newheader); echo "