Ir para conteúdo
Fórum Script Brasil
  • 0

Me ajudem pf, é facil pra quem sabe minimamente disso!!


arthurriobr

Pergunta

1 resposta a esta questão

Posts Recomendados

  • 0
<html lang="pt">
<meta charset="utf-8">
<head>
<title>Um programa que monta tabela</title>
<script>
function start() {
  tbl=document.createElement("table")
  tblBody=document.createElement("tbody")
  row=document.createElement("tr")
  cell=document.createElement("td")
  cellText=document.createTextNode("Aluno(a)")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  cell=document.createElement("td")
  cellText=document.createTextNode("Nota")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  row=document.createElement("tr")
  cell=document.createElement("td")
  cellText=document.createTextNode("= = = = =")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  cell=document.createElement("td")
  cellText=document.createTextNode("= = = = =")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  row=document.createElement("tr")
  cell=document.createElement("td")
  cellText=document.createTextNode("João")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  cell=document.createElement("td")
  cellText=document.createTextNode("9.0")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  row=document.createElement("tr")
  cell=document.createElement("td")
  cellText=document.createTextNode("Carlos")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  cell=document.createElement("td")
  cellText=document.createTextNode("DEZ")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  row=document.createElement("tr")
  cell=document.createElement("td")
  cellText=document.createTextNode("Margarida")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  cell=document.createElement("td")
  cellText=document.createTextNode("12.5")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  row=document.createElement("tr")
  cell=document.createElement("td")
  cellText=document.createTextNode("Diana")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  cell=document.createElement("td")
  cellText=document.createTextNode("15.0")
  cell.appendChild(cellText)
  row.appendChild(cell)
  tblBody.appendChild(row)
  tbl.appendChild(tblBody)
  document.body.appendChild(tbl)
  }
</script>
</head>
<body onload="start()"></body>
</html>

 

Link para o comentário
Compartilhar em outros sites

Participe da discussão

Você pode postar agora e se registrar depois. Se você já tem uma conta, acesse agora para postar com sua conta.

Visitante
Responder esta pergunta...

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emoticons são permitidos.

×   Seu link foi incorporado automaticamente.   Exibir como um link em vez disso

×   Seu conteúdo anterior foi restaurado.   Limpar Editor

×   Você não pode colar imagens diretamente. Carregar ou inserir imagens do URL.



  • Estatísticas dos Fóruns

    • Tópicos
      152k
    • Posts
      651,8k
×
×
  • Criar Novo...