javascript - I cannot append a child element to a list -


I was able to include a child in a dynamic list but for some reason JavaScript functions stopped working. . Also the error console does not throw any errors and I have several warning ('') methods in between the code, to ensure that the method is actually running. This is what I used to do and it is used to work perfectly:

  var o = document.getElementById ('searchResults'); Var li = document.create element ('li'); // Creates a list item tag // If the counter also highlights a strange cell, then ((counter)% 2 == 0) {li.setAttribute ('class', 'par'); } And {li.setAttribute ('class', 'non'); } // I have copied the internal HTML from the displayed line. I have got rid of dynamic variables / simply understanding that is a little easier. Li.innerHTML = "& lt; label class = 'list3p1' & gt; Test & lt; / labels & gt; & lt; label class = 'list3p2' & gt; test2 & lt; / labels & gt; & lt ; Label class = 'list3p3' 'gt; 2: 23 & lt; / label & gt; "; O.appendChild (Lee);   

This function was working, but as I added index.php to other tables, this function was turned off. Apart from this, I have used similar method in other pages. Apart from this, other methods are also working and it is the only work that does not seem to work.

It was done with visibility It took a long time to find me I repeated the table id And the visibility of the second table was hidden so I was adding items to a hidden table. Sorry for the silly question

Comments