public function __construct($errcode, $a1 = null, $a2 = null, $a3 = null, $a4 = null, $a5 = null) { // make sure everything is assigned properly $errtxt = new ErrMsgText(); JpGraphError::SetTitle('JpGraph Error: ' . $errcode); parent::__construct($errtxt->Get($errcode, $a1, $a2, $a3, $a4, $a5), 0); }
die($msg); } else { define('TTF_DIR', $sroot . '/fonts/'); } } else { define('TTF_DIR', '/usr/share/fonts/truetype/'); } } // // Setup path for MultiByte TTF fonts (japanese, chinese etc.) // if (!defined('MBTTF_DIR')) { if (strstr(PHP_OS, 'WIN')) { $sroot = getenv('SystemRoot'); if (empty($sroot)) { $t = new ErrMsgText(); $msg = $t->Get(12, $file, $lineno); die($msg); } else { define('MBTTF_DIR', $sroot . '/fonts/'); } } else { define('MBTTF_DIR', '/usr/share/fonts/truetype/'); } } // // Check minimum PHP version // function CheckPHPVersion($aMinVersion) { list($majorC, $minorC, $editC) = preg_split('/[\\/.-]/', PHP_VERSION);
function Headers() { // In case we are running from the command line with the client version of // PHP we can't send any headers. $sapi = php_sapi_name(); if ($sapi == 'cli') { return; } // These parameters are set by headers_sent() but they might cause // an undefined variable error unless they are initilized $file = ''; $lineno = ''; if (headers_sent($file, $lineno)) { $file = basename($file); $t = new ErrMsgText(); $msg = $t->Get(10, $file, $lineno); die($msg); } if ($this->expired) { 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, must-revalidate"); header("Pragma: no-cache"); } header("Content-type: image/{$this->img_format}"); }
function RaiseL($errnbr, $a1 = null, $a2 = null, $a3 = null, $a4 = null, $a5 = null) { global $__jpg_err; $t = new ErrMsgText(); $msg = $t->Get($errnbr, $a1, $a2, $a3, $a4, $a5); $tmp = new $__jpg_err(); $tmp->Raise($msg); }
public static function RaiseL($errnbr, $a1 = null, $a2 = null, $a3 = null, $a4 = null, $a5 = null) { $t = new ErrMsgText(); $msg = $t->Get($errnbr, $a1, $a2, $a3, $a4, $a5); self::$__jpg_err->Raise($msg); }
function Headers() { $sapi = php_sapi_name(); if ($sapi == 'cli') { return; } $file = ''; $lineno = ''; if (headers_sent($file, $lineno)) { $file = basename($file); $t = new ErrMsgText(); $msg = $t->Get(10, $file, $lineno); die($msg); } if ($this->expired) { 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, must-revalidate"); header("Pragma: no-cache"); } header("Content-type: image/{$this->img_format}"); }