[ Index ] |
|
Code source de eGroupWare 1.2.106-2 |
1 <?php 2 /**************************************************************************\ 3 * eGroupWare - ProjectManager - output a gantchart-image * 4 * http://www.egroupware.org * 5 * Written and (c) 2005 by Ralf Becker <RalfBecker@outdoor-training.de> * 6 * -------------------------------------------- * 7 * This program is free software; you can redistribute it and/or modify it * 8 * under the terms of the GNU General Public License as published by the * 9 * Free Software Foundation; either version 2 of the License, or (at your * 10 * option) any later version. * 11 \**************************************************************************/ 12 13 /* $Id: ganttchart.php 22107 2006-07-13 14:07:27Z ralfbecker $ */ 14 15 /** 16 * As ganttcharts contain an image-map and the image, we save the image as a temporary file. 17 * This for performance reasons, it saves a second creation / script-run. 18 * This script reads and output the temporary file/image and unlinks it after. 19 * If the temp. image is not found, it creates a new one. 20 * It can be used standalone, eg. from SiteMgr. 21 */ 22 error_reporting(E_ALL & ~E_NOTICE); 23 24 $tmp = $GLOBALS['egw_info']['server']['temp_dir']; 25 if (!$tmp || !is_dir($tmp) || !is_writable($tmp)) 26 { 27 @unlink($tmp = tempnam('','test')); // get the systems temp-dir 28 $tmp = dirname($tmp); 29 } 30 if (isset($_GET['img']) && is_readable($ganttchart = $tmp.'/'.basename($_GET['img']))) 31 { 32 header('Content-type: image/png'); 33 readfile($ganttchart); 34 @unlink($ganttchart); 35 exit; 36 } 37 38 $GLOBALS['egw_info'] = array( 39 'flags' => array( 40 'currentapp' => 'projectmanager', 41 'noheader' => True, 42 'nonavbar' => True 43 )); 44 include('../header.inc.php'); 45 46 ExecMethod('projectmanager.ganttchart.create'); 47 48 $GLOBALS['egw']->common->egw_exit();
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Sun Feb 25 17:20:01 2007 | par Balluche grâce à PHPXref 0.7 |