Tengo una página web con los siguientes elementos:
<div style="float: right; margin: 10px;">
Hora UTC:
<label id="HoraUtc" style="font-weight: bold"/>
</div>
<div class="cliente" id="client">
</div>
donde coloco otros elementos de forma dinámica en el div client desde
javascript
:
document.getElementById("client").innerHTML = CODIGO
y todo va bien, pero en el momento en que pongo un texto en el elemento
HoraUtc de la siguiente forma:
document.getElementById("HoraUtc").innerHTML = TEXTO
se borra el contenido que puse previamente en client.
Si declaro HoraUtc de la siguiente forma entonces ya funciona bien:
<label id="HoraUtc" style="font-weight: bold">algo</label>
Creo que el problema es el declarar un label sin contenido ni etiqueta de
cierre.
----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.
http://www.microsoft.com/communities...orer. general