-
Notifications
You must be signed in to change notification settings - Fork 0
/
timers.php
135 lines (117 loc) · 4.28 KB
/
timers.php
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>Temporizadores</title>
<meta http-equiv="Content-type" content="text/html;charset=UTF-8">
<style type="text/css">
@import url(http://d3g0gp89917ko0.cloudfront.net/v--50456838fc8c/common--theme/base/css/style.css);
@import url(http://d3g0gp89917ko0.cloudfront.net/v--50456838fc8c/common--theme/shiny/css/style.css);
@import url(http://05command.wdfiles.com/local--theme/scp-custom-2/style.css);
body
{
font-family: verdana,arial,helvetica,sans-serif;
font-size: 0.82em;
color: #000;
}
table
{
border-collapse: collapse;
}
table, th, td
{
font-size: 1em;
border: 1px solid #000;
text-align: center;
}
input
{
font-size: 1em;
}
#code
{
border: 1px #000 dashed;
background-color: #eee;
width: 600px;
padding: 5px;
margin-top: 20px;
display: none;
}
#preview
{
width: 600px;
height: 75px;
border: 0;
}
#timer
{
border: 2px inset;
font-family: verdana,arial,helvetica,sans-serif;
font-size: 0.82em;
color: #000;
padding: 10px;
font-weight: bold;
width: 350px;
height: 35px;
}
#text
{
color: #D12A21;
}
</style>
<script src='timers.js'></script>
</head>
<body onLoad="selectTimer('0', <?php echo (TEST) ? 'true' : 'false'; ?>);">
<form id="typeForm">
<fieldset>
<legend>Seleccione el tipo de temporizador que necesite crear</legend>
<select name="type" id="type" size="1" onChange="selectTimer(this.options[this.options.selectedIndex].value, <?php echo (TEST) ? 'true' : 'false'; ?>);">
<option value="0" selected>Eliminación</option>
<option value="1">Ban</option>
<option value="2">Genérico</option>
</select>
</fieldset>
</form>
<form name="timerForm" id="timerForm" action="" method="" style="display: none;">
<fieldset id="global">
<legend>Opciones generales</legend>
<div id="customTimerTextOption">
<label for="customTimerText">Texto del temporizador a mostrar:</label>
<input name="customTimerText" id="customTimerText" type="text" size="25" maxlength="150" value="Este temporizador expira en"><br>
</div>
<label for="startNow" id="startNowLabel">¿Comenzar temporizador ahora?</label>
<input id="startNowY" type="radio" name="startNow" checked onClick="toggleFieldset('start', 0);"> Si <input id="startNowN" name="startNow" type="radio" onClick="toggleFieldset('start', 1);"> No
</fieldset>
<fieldset id="start" style="display: none;">
<legend>Fecha/tiempo de inicio</legend>
<select id="startDate" size="1">
</select>
<select id="startTimeH" size="1">
</select>
<select id="startTimeM" size="1">
</select>
</fieldset>
<fieldset id="duration">
<legend>Duración</legend>
<input id="duration1h" type="radio" name="duration" onClick="toggleFieldset('customDuration', 0);"> 1 hr
<input id="duration24h" type="radio" name="duration" onClick="toggleFieldset('customDuration', 0);" checked> 24 hrs
<input id="duration48h" type="radio" name="duration" onClick="toggleFieldset('customDuration', 0);"> 48 hrs
<input id="duration72h" type="radio" name="duration" onClick="toggleFieldset('customDuration', 0);"> 72 hrs
<input id="duration1w" type="radio" name="duration" onClick="toggleFieldset('customDuration', 0);"> 1 sem
<input id="durationc" type="radio" name="duration" onClick="toggleFieldset('customDuration', 1);"> Personalizable
</fieldset>
<fieldset id="customDuration" style="display: none;">
<legend>Duración Personalizable</legend>
<input name="customDurationAmt" id="customDurationAmt" type="text" size="2" maxlength="2" value="" onBlur="if (!isNumber(this.value)) alert('Por favor provee un valor numérico');">
<select name="customDurationUnit" id="customDurationUnit" size="1">
<option value="1"> horas
<option value="2"> días
<option value="3"> semanas
</select>
</fieldset>
<input type="button" name="generate" id="generate" value="Generar código de temporizador" onClick="generateCode(document.getElementById('type').options[document.getElementById('type').options.selectedIndex].value, null, null, null);">
</form>
<div id="articles"></div>
<div id="code"></div>
<div id="preview"></div>
</body>
</html>