Ver Mensaje Individual
  #1 (permalink)  
Antiguo 19/10/2012, 14:30
isabelramirezmontoya
 
Fecha de Ingreso: noviembre-2010
Mensajes: 204
Antigüedad: 13 años, 5 meses
Puntos: 1
Cambiar funcion en enlace

Chicos tengo una duda me colaboran por favor

Tengo el siguiente codigo:

Código HTML:
Ver original
  1.  
  2.  
  3. <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\" />
  4.  
  5. <title>Formulario nota nueva</title>
  6.  
  7. <script type="text/javascript">
  8.        
  9. function boton_inicio()
  10. {
  11.   document.getElementById('boton').innerHTML="Final";
  12.  
  13. }
  14.  
  15. function boton_final()
  16. {
  17.    document.getElementById('boton').innerHTML="Inicio";
  18.  
  19. }
  20.  
  21.  
  22. </head>
  23.  
  24.  
  25. <div id="boton"><a href="javascript:boton_inicio();">Inicio</a></div>
  26.  
  27. </body>
  28. </html>

Necesito cambiar el nombre y la funcion del enlace al oprimir el enlace

Al oprimir el enlace quiero cambiar el nombre del enlace (Inicio por Final) y la funcion (boton_inicio() por boton_final()), ya logre cambiar el nombre del enlace, pero no se como cambiar el nombre de la funcion.

Gracias