var counter=0;function onClick(){var e=document.getElementById("element"),t=document.getElementById("menge");console.log(e.value),add(e.value,t.value)}function add(e,t){counter++;var n=document.getElementById("liste"),c=document.createElement("input");c.setAttribute("type","checkbox"),c.setAttribute("id","cb"+counter),c.setAttribute("class","checkmark");var d=document.createElement("label");d.innerHTML=e+"  "+t,d.setAttribute("for","cb"+counter),n.appendChild(c),n.appendChild(d),n.appendChild(document.createElement("br"))}