Thanks alot thats right on the track I was looking for. Here's what I got now...function PopWindow() { if (document.getElementById('btn1')) { window.open("itempage01.html", "myWindow", "status=1, height=450, width=550, resizable=0"); } else if (document.getElementById('btn2')) { window.open("itempage02.html", "myWindow", "status=1, height=450, width=550, resizable=0"); } else { }}
Right now both buttons are popping up only "itempage01.html". Am I missing something in my condition?