forked from azza-bazoo/prettycron
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample.html
More file actions
41 lines (38 loc) · 1.53 KB
/
Copy pathexample.html
File metadata and controls
41 lines (38 loc) · 1.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<!DOCTYPE html>
<html>
<head>
<title>Human readable cron schedule examples</title>
</head>
<body>
<p style="font-style:italic">generated by <a href="http://github.com/azza-bazoo/prettycron">prettyCron</a></p>
<div id="output">Loading ...</div>
<script src="https://raw.github.com/bunkat/later/master/later-cron.min.js" type="text/javascript"></script>
<script src="https://raw.github.com/timrwood/moment/develop/min/moment.min.js" type="text/javascript"></script>
<script src="prettycron.js" type="text/javascript"></script>
<script type="text/javascript">
var printCron = function(cron) {
document.getElementById('output').innerHTML +=
'<p><b>Cron expression:</b> <code>' + cron + '</code><br/>'
+ '<b>Human readable:</b> ' + prettyCron.toString(cron) + '<br/>'
+ '<b>Next run:</b> ' + prettyCron.getNext(cron) + '</p>';
}
window.addEventListener('load', function() {
document.getElementById('output').innerHTML = '';
printCron('0 * * * *');
printCron('30 * * * 1');
printCron('15,45 9,21 * * *');
printCron('18,19 7 5 * *');
printCron('* * 25 12 *');
printCron('0 * 1,3 * *');
printCron('0 17 * 1,4,7,10 *');
printCron('15 * * * 1,2');
printCron('* 8,10,12,14,16,18,20 * * * ');
printCron('0 12 15,16 1 3');
printCron('0 4,8,12,4 * * 4,5,6');
printCron('0 2,16 1,8,15,22 * 1,2');
printCron('15 3,8,10,12,14,16,18 16 * *');
printCron('2 8,10,12,14,16,18 * 8 0,3 ');
});
</script>
</body>
</html>