mikelawrence
Programmer
I can open a window in a javascript function as
function poptastic(name,widthy,heightx)
{
url="images/locations/"+name ;
newwindow=window.open(url,'name','height='+heightx+',width='+widthy);
if (window.focus) {newwindow.focus()}
}
but how do i prompt the user to close the popup? I know how to do this if i was closing from within an html page but if you can open a window from javascript there must be a way of closing it from within the popup. I guess you would use self.close(?) or newwidow.close but if so how do i prompt the user to click on something to action this?
I'd appreciate any advice
thanks
mike
function poptastic(name,widthy,heightx)
{
url="images/locations/"+name ;
newwindow=window.open(url,'name','height='+heightx+',width='+widthy);
if (window.focus) {newwindow.focus()}
}
but how do i prompt the user to close the popup? I know how to do this if i was closing from within an html page but if you can open a window from javascript there must be a way of closing it from within the popup. I guess you would use self.close(?) or newwidow.close but if so how do i prompt the user to click on something to action this?
I'd appreciate any advice
thanks
mike