Monday, November 27, 2006

open links in new,current,background, window, in Java script.


how to open links in current window, new window, background.

use this java script code:



function
open2(url, opt){
if (opt == 0) // current window
window.location = url;
else if (opt == 1)
// new window
window.open(url);
else if (opt == 2) // background window
{window.open(url); self.focus();}
}


ok bye..

No comments:

Pay Pal

Sign up for PayPal and start accepting credit card payments instantly.

Ruby Corner

Earn Money