javascript - How can I make a simple table row with numbers using .appendChild? -
I am a beginner programmer and I wonder if someone can help me.
I want to find a table with row and 7 numbers in table data & amp; Function Response Feedback I tried to do this but it does not work, and I'm looking for it for some time now:
& lt; Html & gt; & Lt; Top & gt; & Lt; Script type = "text / javascript" & gt; Ceremony maaktable () {warning ("hey!"); Var tabdata = tabrow.appendChild (document.createElement ("td"). InnerText = Amount [i]; var tabrow = tablestart.appendChild (document.createElement ("tr"); var tablestart = document.createElement ("table") (I = 0; i & lt; 6; i ++) {tabdata;}}
script> gt; & lt; / head> gt; & lt; body & gt; & gt; button onclick = " Maaktable () "& gt; Beginning <; Button & gt; & lt; / body & gt; & lt; / html & gt; The problem is also not cautious What can I do to make this work?
Not sure that this is desired The result is, but your code looks a bit far away, etc. You should get at least alerts and hopefully you go on the right path
function maaktable () {Warning ("Hey!"); Var tablestart = document.createElement ("table") ; Var tabrow = tablestart.appendChild (document .createElement ("tr"); (i = 0; i & lt; 6; i ++) {// tabdata; tabrow.appendChild (document.createElement ("TD") . InnerText (zodiac [i]));}}
Comments
Post a Comment