mirror of
https://github.com/e107inc/e107.git
synced 2025-03-14 09:29:45 +01:00
Removed some PHP notices occurring in CLI mode.
This commit is contained in:
parent
e1593de8ee
commit
0f02e9a9a2
@ -1532,7 +1532,7 @@ if(!defined("THEME_LAYOUT"))
|
|||||||
$pref = e107::getPref();
|
$pref = e107::getPref();
|
||||||
$cusPagePref = (!empty($user_pref['sitetheme_custompages'])) ? $user_pref['sitetheme_custompages'] : varset($pref['sitetheme_custompages'],array());
|
$cusPagePref = (!empty($user_pref['sitetheme_custompages'])) ? $user_pref['sitetheme_custompages'] : varset($pref['sitetheme_custompages'],array());
|
||||||
$cusPageDef = (empty($user_pref['sitetheme_deflayout'])) ? varset($pref['sitetheme_deflayout'],'') : $user_pref['sitetheme_deflayout'];
|
$cusPageDef = (empty($user_pref['sitetheme_deflayout'])) ? varset($pref['sitetheme_deflayout'],'') : $user_pref['sitetheme_deflayout'];
|
||||||
$deflayout = e107::getTheme()->getThemeLayout($cusPagePref, $cusPageDef, e_REQUEST_URL, $_SERVER['SCRIPT_FILENAME']);
|
$deflayout = e107::getTheme()->getThemeLayout($cusPagePref, $cusPageDef, e_REQUEST_URL, varset($_SERVER['SCRIPT_FILENAME']));
|
||||||
|
|
||||||
define("THEME_LAYOUT",$deflayout);
|
define("THEME_LAYOUT",$deflayout);
|
||||||
|
|
||||||
|
@ -168,6 +168,17 @@ class _system_cron
|
|||||||
$message .= $this->renderTable($_SERVER);
|
$message .= $this->renderTable($_SERVER);
|
||||||
$message .= "<h3>_ENV</h3>";
|
$message .= "<h3>_ENV</h3>";
|
||||||
$message .= $this->renderTable($_ENV);
|
$message .= $this->renderTable($_ENV);
|
||||||
|
$message .= "<h3>LAST ERROR</h3>";
|
||||||
|
$message .= "<pre>".print_r(error_get_last(), true)."</pre>";
|
||||||
|
$message .= "<h3>HEADERS LIST</h3>";
|
||||||
|
$message .= "<pre>".print_r(headers_list(),true)."</pre>";
|
||||||
|
$message .= "<h3>Included Files</h3>";
|
||||||
|
$included_files = get_included_files();
|
||||||
|
|
||||||
|
foreach ($included_files as $filename)
|
||||||
|
{
|
||||||
|
$message .= $filename."<br />";
|
||||||
|
}
|
||||||
|
|
||||||
$eml = array(
|
$eml = array(
|
||||||
'subject' => "TEST Email Sent by cron. ".date("r"),
|
'subject' => "TEST Email Sent by cron. ".date("r"),
|
||||||
@ -459,7 +470,7 @@ class CronParser
|
|||||||
function calcLastRan($string)
|
function calcLastRan($string)
|
||||||
{
|
{
|
||||||
|
|
||||||
$tstart = microtime();
|
$tstart = microtime(true);
|
||||||
$this->debug = "";
|
$this->debug = "";
|
||||||
$this->lastRan = 0;
|
$this->lastRan = 0;
|
||||||
$this->year = NULL;
|
$this->year = NULL;
|
||||||
@ -589,7 +600,7 @@ class CronParser
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$tend = microtime();
|
$tend = microtime(true);
|
||||||
$this->taken = $tend - $tstart;
|
$this->taken = $tend - $tstart;
|
||||||
$this->debug("Parsing $string taken " . $this->taken . " seconds");
|
$this->debug("Parsing $string taken " . $this->taken . " seconds");
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user