I need to open certain links in a new window (NOT TAB) with certain dimensions.
This will open a link in new tab:
$(document).ready(function() {
$('a[rel|=external]').click(function(){
window.open(this.href);
return false;
});
});
What to change in order to get links opening in new windows.?
EDIT: This is my entire javascript file:
$(document).ready(function() {
$('a[rel=external]').click(function(){
window.open(this.href);
return false;
});
$('a[rel=external-new-window]').click(function(){
window.open(this.href, "myWindowName", "width=800, height=600");
return false;
});
});
HTML:
<a href="/clientarea/utils/law/id/2832" rel="external-new-window" class="accessible-link">§5, odsek 2</a>