Original Post
I have a quick question which has caused me to waste this entire day trying to do something so stupidly simple it makes me want to impale myself on a rusty pitchfork. I have a function that is called every time I press a button. The function adds a text field to a div tag. After adding it I want to insert the HTML tag < BR>, so that the next field that gets added is on a new line. I can't figure it out how to tell the javascript to write this. Any ideas? This has been a bad week. Based on some code another member donated to me
var num = [0];
function add()
{
var txt = document.createElement("input");
txt.setAttribute("type", "text");
txt.setAttribute("size", "[40]");
txt.id = "spotlight_images" + num;
txt.name = "spotlight_images" + num;
txt.value = txt.id;
document.getElementById('spotlight_images').appendChild(txt);
num++;
}