-1
I’m picking to put a clock inside a tag
I have this code for the function of the clock I picked up on the Internet
function startTime() {
var today = new Date();
var h = today.getHours();
var m = today.getMinutes();
var s = today.getSeconds();
m = checkTime(m);
s = checkTime(s);
document.getElementById('txt').innerHTML =
h + ":" + m + ":" + s;
var t = setTimeout(startTime, 500);
}
function checkTime(i) {
if (i < 10) {i = "0" + i}; // add zero in front of numbers < 10
return i;
}
In this example shows me to insert the clock this way
<body onload="startTime()">
<p id="demo"></p>
<div id="txt"></div>
But I want to put it in the code that says, "Waiting time." because it is the waiting time of the customer for the return of the call.
<td>0001</td>
<td>11:05</td>
<td>Suporte</td>
<td>Luciana</td>
<td>5292 - J ALVES CONTABIL</td>
<td>Norma</td>
<td>Tempo de espera</td>
Could you help me?
Welcome Fabio Ozuna, ever toured the site? https://answall.com/tour
– user60252