Questions tagged as 'setinterval'

1
answer

Update a PHP variable within a Javascript function

I am using the following code to display the current time of the server: <p id="demo"></p> <script> function segundoAtual() { var n = <?php date_default_timezone_set('America/Sao_Paulo'); $cH = date('G');...
asked by 07.03.2017 / 02:01
1
answer

JavaScript Clock increase for game

I am creating a team in JS to count the time the user will take to complete the task. I am using setInterval() to run the team but I am not able to increment to more than (1) the value of min() . This is my code: const time = {...
asked by 31.08.2018 / 23:02
2
answers

Timing with setInterval in JS

I'm trying to make a timer, until it's working, the problem is that it only slows down if I click, and I need it to go away once I click once. var mins = "30"; var secs = "00"; function timeCount(){ if (secs == "00"){ s...
asked by 21.05.2016 / 04:59
0
answers

Does leaving active setInterval cause site slowness? [duplicate]

For example, I have a setInterval that will get every 1 second checking if the company chat is with an online attendant. If an attendant comes online, I give a clearInterval and stop the function, but if no attendant goes online, it keeps runn...
asked by 22.06.2018 / 21:26
0
answers

Automatic refresh without google maps

I work with a vehicle tracking system, but it was not developed by me, I got the project already in progress. I need in my page where the whole tracking procedure is done as the vehicle's current location, it becomes automatic, today to have...
asked by 30.08.2016 / 14:40