本文整理汇总了PHP中module_controller::noexists方法的典型用法代码示例。如果您正苦于以下问题:PHP module_controller::noexists方法的具体用法?PHP module_controller::noexists怎么用?PHP module_controller::noexists使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类module_controller
的用法示例。
在下文中一共展示了module_controller::noexists方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: CheckCronForErrors
static function CheckCronForErrors()
{
global $zdbh;
global $controller;
$retval = FALSE;
//Try to create the cron file if it doesnt exist...
if (!file_exists(ctrl_options::GetSystemOption('cron_file'))) {
fs_filehandler::UpdateFile(ctrl_options::GetSystemOption('cron_file'), 0644, "");
}
$currentuser = ctrl_users::GetUserDetail();
// Check to make sure the cron is not blank before we go any further...
if ($controller->GetControllerRequest('FORM', 'inScript') == '') {
self::$blank = TRUE;
$retval = TRUE;
}
// Check to make sure the cron script exists before we go any further...
if (!is_file(fs_director::RemoveDoubleSlash(fs_director::ConvertSlashes(ctrl_options::GetSystemOption('hosted_dir') . $currentuser['username'] . '/public_html/' . $controller->GetControllerRequest('FORM', 'inScript'))))) {
self::$noexists = TRUE;
$retval = TRUE;
}
// Check to see if creating system cron file was successful...
if (!is_file(ctrl_options::GetSystemOption('cron_file'))) {
self::$cronnoexists = TRUE;
$retval = TRUE;
}
// Check to makesystem cron file is writable...
if (!is_writable(ctrl_options::GetSystemOption('cron_file'))) {
self::$cronnowrite = TRUE;
$retval = TRUE;
}
// Check to make sure the cron is not a duplicate...
$sql = "SELECT COUNT(*) FROM x_cronjobs WHERE ct_acc_fk=:userid AND ct_script_vc=:inScript AND ct_deleted_ts IS NULL";
$numrows = $zdbh->prepare($sql);
$numrows->bindParam(':userid', $currentuser['userid']);
$numrows->bindParam(':inScript', $controller->GetControllerRequest('FORM', 'inScript'));
if ($numrows->execute()) {
if ($numrows->fetchColumn() != 0) {
self::$alreadyexists = TRUE;
$retval = TRUE;
}
}
return $retval;
}