Monday, November 24, 2008

JavaScript Tutorials Part-III

  • Script for Closing window if opened Independently:


window.onload=function()

{

if(!window.opener)

window.close();

}


  • Script for Clear Authentication Cookie:

function _spBosyOnLoad()

{

try

{

document.execCommand(“ClearAuthenticationCache”);

window.close();

}

catch(e){}

}

No comments: