tags:

views:

30

answers:

1

Hello everyone,

My situation is that, I have page contains a button and some links. Whenever user click on the button, it tries to append tag <base> to <head>

function avoidRediect(){
    $('head').append('<base target="_blank" />');
}

But the page does not take the effect(means the link is still opened in the same window). Is my way correct? Thank in advance.

A: 

Actually this should work.

Example: http://www.jsfiddle.net/YjC6y/37/

If you remove the Javascript line it will open in the same frame.

What browser do you use there?

jAndy
Yeah, I works with IE but not FF. How can I make it work with both IE and FF ?
SunB