Ark86
12-18-2002, 11:21 PM
OK, here is my code to open a new window and dynamically write some text to it (it is supposed to be just an image). I just can't figure out how to have the first picture dissappear after I click on another link to another picture without closing the new window. I want it to appear in the same window, but it just adds the picture below the last one. I know why it is doing it, but I don't know how to fix it. Thanks.
Here is my code:
function newPicWindow(imageURL, title) {
picWindow=window.open("", "picWindow", "height=650, width=640, resizable=no, menubar=no, toolbar=no, screenX=100, screenY=100");
picWindow.document.write("<html><head><title>"+title+"</title></head><body>");
picWindow.document.write("<img src="+imageURL+"><br>");
picWindow.document.write("</body></html>");
}
Here is my code:
function newPicWindow(imageURL, title) {
picWindow=window.open("", "picWindow", "height=650, width=640, resizable=no, menubar=no, toolbar=no, screenX=100, screenY=100");
picWindow.document.write("<html><head><title>"+title+"</title></head><body>");
picWindow.document.write("<img src="+imageURL+"><br>");
picWindow.document.write("</body></html>");
}