mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-14 01:48:47 +01:00
fixed calendar to be printer friendly
This commit is contained in:
parent
be3d70940f
commit
327588521e
@ -18,7 +18,9 @@
|
||||
if (isset($friendly) && $friendly){
|
||||
$phpgw_info["flags"]["noheader"] = True;
|
||||
$phpgw_info["flags"]["nonavbar"] = True;
|
||||
$phpgw_info["flags"]["nocalendarheader"] = True;
|
||||
$phpgw_info["flags"]["noappheader"] = True;
|
||||
$phpgw_info["flags"]["noappfooter"] = True;
|
||||
$phpgw_info["flags"]["nofooter"] = True;
|
||||
} else {
|
||||
$friendly = 0;
|
||||
}
|
||||
@ -88,7 +90,7 @@
|
||||
$phpgw->template->set_var("small_calendar",$phpgw->calendar->pretty_small_calendar($now["day"],$now["month"],$now["year"],"day.php"));
|
||||
|
||||
if (!$friendly) {
|
||||
$param = 'year='.$thisyear.'&month='.$thismonth.'&friendly=1&filter='.$filter;
|
||||
$param = 'year='.$thisyear.'&month='.$thismonth.'&day='.$thisday.'&friendly=1&filter='.$filter;
|
||||
$phpgw->template->set_var("print","<a href=\"".$phpgw->link("",$param)."\" TARGET=\"cal_printer_friendly\" onMouseOver=\"window.status = '".lang("Generate printer-friendly version")."'\">[".lang("Printer Friendly")."]</A>");
|
||||
$phpgw->template->parse("out","day_t");
|
||||
$phpgw->template->pparse("out","day_t");
|
||||
|
@ -1099,10 +1099,16 @@
|
||||
$p->set_var('dayname',$str);
|
||||
}
|
||||
} else {
|
||||
$p->set_var('bgcolor2','#FEFEFE');
|
||||
$p->set_var('dayname','<a href="'.$phpgw->link($phpgw_info["server"]["webserver_url"]
|
||||
. '/calendar/'.$link,'year='.$cal["year"].'&month='.$cal["month"].'&day='
|
||||
. $cal["day"]).'" class="minicalendargrey">' . $cal["day"] . "</a>");
|
||||
$p->set_var('bgcolor2','#FEFEFE');
|
||||
$str = "";
|
||||
if(!$this->printer_friendly) {
|
||||
$str .= '<a href="'.$phpgw->link($phpgw_info["server"]["webserver_url"]
|
||||
. '/calendar/'.$link,'year='.$cal["year"].'&month='.$cal["month"].'&day='
|
||||
. $cal["day"]).'" class="minicalendargrey">';
|
||||
}
|
||||
$str .= $cal["day"];
|
||||
if (!$this->printer_friendly) $str .= '</a>';
|
||||
$p->set_var('dayname',$str);
|
||||
}
|
||||
$p->parse('monthweek_day','mini_day',True);
|
||||
}
|
||||
|
@ -18,7 +18,9 @@
|
||||
if (isset($friendly) && $friendly){
|
||||
$phpgw_info["flags"]["noheader"] = True;
|
||||
$phpgw_info["flags"]["nonavbar"] = True;
|
||||
$phpgw_info["flags"]["nocalendarheader"] = True;
|
||||
$phpgw_info["flags"]["noappheader"] = True;
|
||||
$phpgw_info["flags"]["noappfooter"] = True;
|
||||
$phpgw_info["flags"]["nofooter"] = True;
|
||||
} else {
|
||||
$friendly = 0;
|
||||
}
|
||||
|
@ -18,7 +18,9 @@
|
||||
if (isset($friendly) && $friendly){
|
||||
$phpgw_info["flags"]["noheader"] = True;
|
||||
$phpgw_info["flags"]["nonavbar"] = True;
|
||||
// $phpgw_info["flags"]["nocalendarheader"] = True;
|
||||
$phpgw_info["flags"]["noappheader"] = True;
|
||||
$phpgw_info["flags"]["noappfooter"] = True;
|
||||
$phpgw_info["flags"]["nofooter"] = True;
|
||||
} else {
|
||||
$friendly = 0;
|
||||
}
|
||||
|
@ -12,13 +12,17 @@
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
$phpgw_info["flags"] = array("currentapp" => "calendar", "enable_nextmatchs_class" => True);
|
||||
|
||||
if (isset($friendly) && $friendly){
|
||||
$phpgw_info["flags"]["noheader"] = True;
|
||||
$phpgw_info["flags"]["nonavbar"] = True;
|
||||
$phpgw_info["flags"]["noappheader"] = True;
|
||||
$phpgw_info["flags"]["noappfooter"] = True;
|
||||
$phpgw_info["flags"]["nofooter"] = True;
|
||||
} else {
|
||||
$friendly = 0;
|
||||
}
|
||||
|
||||
$phpgw_info["flags"] = array("currentapp" => "calendar", "enable_nextmatchs_class" => True);
|
||||
include("../header.inc.php");
|
||||
|
||||
$view = "year";
|
||||
|
@ -1,4 +1,7 @@
|
||||
[0.9.10] - Fixed the cron programs, they where out of date in the table structures
|
||||
- Added the ["flags"]["nofooter"] . ["flags"]["noappfooter"] flags.
|
||||
- Fixed calendars in Printer Friendly mode.
|
||||
- Fixed calendar day-view with events spanning multiple hours.
|
||||
|
||||
[0.9.9] - Fixed a number of issues with the verdilak layout
|
||||
- Fixed parse_footer() not working if the header is turned off.
|
||||
|
@ -24,7 +24,8 @@
|
||||
if (file_exists ($phpgw_info["server"]["app_inc"]."/footer.inc.php")
|
||||
&& $phpgw_info["flags"]["currentapp"] != "home"
|
||||
&& $phpgw_info["flags"]["currentapp"] != "login"
|
||||
&& $phpgw_info["flags"]["currentapp"] != "logout"){
|
||||
&& $phpgw_info["flags"]["currentapp"] != "logout"
|
||||
&& (!isset($phpgw_info["flags"]["noappfooter"]) || !$phpgw_info["flags"]["noappfooter"])) {
|
||||
include($phpgw_info["server"]["app_inc"]."/footer.inc.php");
|
||||
}
|
||||
|
||||
|
@ -509,7 +509,10 @@
|
||||
function phpgw_footer()
|
||||
{
|
||||
global $phpgw, $phpgw_info, $HTMLCOMPLAINT;
|
||||
include($phpgw_info["server"]["api_inc"] . "/footer.inc.php");
|
||||
|
||||
if (!isset($phpgw_info["flags"]["nofooter"]) || !$phpgw_info["flags"]["nofooter"]) {
|
||||
include($phpgw_info["server"]["api_inc"] . "/footer.inc.php");
|
||||
}
|
||||
|
||||
// Clean up mcrypt
|
||||
if (is_object($this->crypto)) {
|
||||
|
Loading…
Reference in New Issue
Block a user