I'm using this code i got from codepen to append div nodes to parent div and its working fine.
var el = document.getElementById('items'),
elChild = document.createElement("div");
elChild.innerHTML = '<div class="product"><a href="product1.html"><img src="images/product1.png" alt="product1" /></a></div>'
el.appendChild(elChild);
How can i add more div elements to because i tried adding them as in the code below and it failed, Thanks in advance
var el = document.getElementById('items'),
elChild = document.createElement("div");
elChild.innerHTML = '<div class="product"><a href="product1.html"><img src="images/product1.png" alt="product1" /></a></div>'
'<div class="product"><a href="product2.html"><img src="images/product2.png" alt="product2" /></a></div>'
'<div class="product"><a href="product3.html"><img src="images/product3.png" alt="product3" /></a></div>'
el.appendChild(elChild);