Prevents jobs to collide if they take longer to run than the frequency itself
$fp =
fopen('/tmp/lock.txt',
'r+');
if(!
flock($fp, LOCK_EX | LOCK_NB
)) {
echo 'Unable to obtain lock';
}
/* ... */
Paste this in your website: <script type="text/javascript" src="http://www.posteet.com/embed/2040"></script>