PHP Classes

File: sample/executor.cron.php

Recommend this page to a friend!
  Classes of Martin Pircher   PHP Cron Job Manager Script   sample/executor.cron.php   Download  
File: sample/executor.cron.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP Cron Job Manager Script
Add PHP scripts to be executed periodically
Author: By
Last change: Update of sample/executor.cron.php
Date: 9 months ago
Size: 659 bytes
 

Contents

Class file image Download
#! /usr/bin/php
<?php
/**
 * sample scheduler to be called via cron(tab), anacron ...
 * @version 2009-11-16 17:49:25 +0100
 * @copyright Martin Pircher <mplx+code@donotreply.at>
 * @author Martin Pircher <mplx+code@donotreply.at>
 * @link http://www.pircher.net/
 * @license http://opensource.org/licenses/MIT MIT License
 * @package Cronjob
 */

use \mplx\toolkit\cronjob\CronJob;

/**
 * Database configuration
 */
include 'config.inc.php';

/**
 * Check for CLI
 */
if (@php_sapi_name() != 'cli') {
    die(
'ERROR: This script will only work in the shell'.PHP_EOL);
}

/**
 * Run the cronjob executor
 */
include dirname(__FILE__).'/../src/executor.php';