Archive for the ‘JavaScript’ Category

Base tag, IE and JavaScript
August 31, 2006

If you use the <base> tag, links in JavaScript (window.open for example) will ignore the <base> tag. The way around it is to make the link in the JavaScript relative to the domain.

<base href=”http://www.example.com/this_site/”&gt;

The JavaScript should look like this.

window.open(‘/this_site/page2.html’);

Advertisements