hola,
solo tienes
que ponerlo
en la funcion
onload Código HTML:
onload = function(){
document.getElementById('agregarId').onclick = function() {
row = document.createElement('tr');
head1 = document.createElement('th');
label1 = document.createElement('label');
head2 = document.createElement('th');
label2 = document.createElement('label');
text1 = document.createTextNode("Idiomas");
data1 = document.createElement('td');
input1 = document.createElement('input');
input1.setAttribute("name","idiomas");
input1.setAttribute("type","text");
text2 = document.createTextNode("% de dominio");
data2 = document.createElement('td');
input2 = document.createElement('input');
input2.setAttribute("name","domIdioma");
input2.setAttribute("type","text");
label1.appendChild(text1);
head1.appendChild(label1);
row.appendChild(head1);
row.appendChild(data1);
data1.appendChild(input1);
label2.appendChild(text2);
head2.appendChild(label2);
row.appendChild(head2);
data2.appendChild(input2);
row.appendChild(data2);
document.getElementById('tabla').appendChild(row);
return false;
}
}
saludos...
:]