Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

93
Vistas
Label is not updating after being appended

The following code is opening a jQuery dialog. I wish to move one of the labels (id as EventTime) close to the dialog buttons, at the bottom.

The code:

$("#FireAlert").dialog("open");
$(".ui-dialog-buttonpane").append($("#EventTime"));
function pad(val) {
    return val > 9 ? val : "0" + val;
}
eventTimer = setInterval(function () {
    $("#EventTime").text("Event time - " + pad(parseInt(eventSeconds / 3600 % 60, 10)) + ":" + pad(parseInt(eventSeconds / 60 % 60, 10)) + ":" + pad(++eventSeconds % 60));
}, 1000);

When pausing the timer and inspecting the label, it has the right text, but it is not updating in the browser, i.e. it's still showing the initialized text.

When omitting the append command, the label is updating correctly.

Sample here - https://jsfiddle.net/8s9pceg4

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda