Location: PHPKode > projects > O - OpenSource GroupWare > osgw/scripts/cron_job.php
<?php
/**************************************************************************
   This program is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
   the Free Software Foundation; either version 2 of the License, or
   (at your option) any later version.

   @Authors:	Ryan Thompson(hide@address.com)
***************************************************************************/
include("./data.php");
$service['add_header'] = FALSE;
$service['no_session'] = TRUE;
include('./config.inc.php');

if(isset($_ENV['HTTP_USER_AGENT']))
{
	//Keep people from running script within a browser
	die("This script can't be run within a browser.");
} else {
	$now = time();
	$sql = "DELETE FROM o_sessions WHERE expires < '$now'";
	$O->db->query($sql);
	echo $O->db->num_rows;
	
	
}
?>
Return current item: O - OpenSource GroupWare