![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
02/03/2006, 04:36
|
![Avatar de JavierB](http://static.forosdelweb.com/customavatars/avatar16568_12.gif) | Colaborador | | Fecha de Ingreso: febrero-2002 Ubicación: Madrid
Mensajes: 25.052
Antigüedad: 23 años Puntos: 772 | |
Hola germanpr
Prueba este código:
Código:
<html>
<head>
<script type="text/javascript">
function mostrar(ima,texto) {
document.getElementById('im').src = ima;
document.getElementById('txt').innerHTML = texto;
}
</script>
</head>
<body>
<table border="1">
<tr>
<td onclick="mostrar('imagen1.gif','Hola tú')">Texto 1</td>
<td onclick="mostrar('imagen2.gif','Hasta pronto')">Texto 1</td>
<tr>
<tr>
<td><img id="im" src="" /><span id="txt"> </span></td>
</tr>
</table>
</body>
</html>
Saludos, |