User Tools

Site Tools


how_to_create_a_job_module

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
how_to_create_a_job_module [2019/10/22 23:36]
admin
how_to_create_a_job_module [2019/10/23 00:19] (current)
admin
Line 32: Line 32:
             //if (strtotime($last_run) > strtotime('-1 hour')) return;             //if (strtotime($last_run) > strtotime('-1 hour')) return;
             if (date('Ymdh', strtotime($last_run)) == date('Ymdh')) return;             if (date('Ymdh', strtotime($last_run)) == date('Ymdh')) return;
-            break; 
- 
-          case '2 Hours': 
-            //if (strtotime($last_run) > strtotime('-2 hours')) return; 
-            if (($fraction = ceil(date('hn', strtotime($last_run))/200)) == 0) $fraction++; 
-            if ($fraction == ceil(date('hn')/200)) return; 
-            break; 
- 
-          case '3 Hours': 
-            //if (strtotime($last_run) > strtotime('-3 hours')) return; 
-            if (($fraction = ceil(date('hn', strtotime($last_run))/300)) == 0) $fraction++; 
-            if ($fraction == ceil(date('hn')/300)) return; 
-            break; 
- 
-          case '6 Hours': 
-            //if (strtotime($last_run) > strtotime('-6 hours')) return; 
-            if (($fraction = ceil(date('hn', strtotime($last_run))/600)) == 0) $fraction++; 
-            if ($fraction == ceil(date('hn')/600)) return; 
-            break; 
- 
-          case '12 Hours': 
-            //if (strtotime($last_run) > strtotime('-12 hours')) return; 
-            if (($fraction = ceil(date('hn', strtotime($last_run))/1200)) == 0) $fraction++; 
-            if ($fraction == ceil(date('hn')/1200)) return; 
             break;             break;
  
how_to_create_a_job_module.txt ยท Last modified: 2019/10/23 00:19 by admin