Ver Mensaje Individual
  #7 (permalink)  
Antiguo 09/03/2010, 07:59
Avatar de humanista
humanista
 
Fecha de Ingreso: abril-2005
Mensajes: 878
Antigüedad: 19 años, 1 mes
Puntos: 15
De acuerdo Respuesta: Eliminar o crear capas

De todas formas... tengo este código que muestra un comentario de un foro y un botón "Delete". En el formulario llamo a la función enviarDatos que borrar el registro con AJAX pero no sé cómo acoplar el evento this.parentNode.removeChild(this)...

Alguien sabe cómo puedo hacerlo?

Código PHP:
echo "<div align=justify>$comment</div>"
Código HTML:

<form name="<?echo "a".$id;?>" action="" onsubmit="enviarDatos('<?echo "a".$id;?>'); return false">
							
<table border=0 cellpadding=0 cellspacing=0 width=100%>
    <tr><td>
							
<input class="delete" type="submit" align="left" vspace="2" width="150" height="25" value="Delete" />
							
<input type="hidden" name="id" value="<?php echo $id;?>" />
															
              </td></tr>
							
</table>
							
</form> 

Última edición por humanista; 09/03/2010 a las 13:07