jquery - what is return type of window.open() in Javascript -


i writing code download pdf file using window.open(). passing url path of pdf file on server.

window.open(url, name, "width=910,height=750,scrollbars=yes"); 

i want check if downloading of file successful or not. return type of window.open()?

i tried

try {   window.open(url, name, "width=910,height=750,scrollbars=yes");   alert("success"); } catch(e) {   alert("failer"); } 

when change url wrong url, shows same result success.

http://www.javascripter.net/faq/openinga.htm

the return value reference new window. can use reference later, example, close window (winref.close()), give focus window (winref.focus()) or perform other window manipulations.


Comments

Popular posts from this blog

linux - Using a Cron Job to check if my mod_wsgi / apache server is running and restart -

actionscript 3 - TweenLite does not work with object -

php - How can I edit my code to echo the data of child's element where my search term was found in, in XMLReader? -