d='javascript:if(document.getElementsByTagName("*").length>0&&document.getElementsByTagName("body")[0].innerHTML!=""&&!confirm("You are about to navigate to home page Do you want to do that ? ")){opener.display2WindowHelp();}else{window.location.replace("${pageContext.request.scheme}://${pageContext.request.serverName}:${pageContext.request.serverPort}${pageContext.request.contextPath}'+d+'");}';
b= window.open(d,"_spor_window_"+a+window.location.hostname.replace(/\\./g,""),"menubar=no,scrollbars=yes,height="+screen.availHeight+",width="+screen.availWidth+",left=0,top=0,resizable=yes,toolbar=no,location=no,status=no");
I wrote the above code to open a new window from home window . but its opening a new tab in IE8 . Is there a way to modify this to open a new window instead of new tab in IE8
I agree but a different code is opening a new browser window in the same browser but this is not able to do that … i think i can modify my code to do so …thanks
As a web surfer I find it very annoying when some website wants to open a new window in general. I consider it very spammy and think x2 about visiting sites like that again.
New tabs however, I’m ok with. I’d suggest you just stick with new tab.
Where new web pages open is completely under the control of your visitor. The days when the web page author could force pages to open in a new window ended long before browsers introduced tabs - that’s why no option for opening a new tab was introduced into JavaScript.
it still works in IE8 i guess the problem is with the javascript that i assigned to the variable if i give a url in place of script it holds good and working fine i need to figure out a way for this … any how thanks for your help
So you need to configure each copy of the browser to always open pages that request it in a new window. Of course that will then apply to requests from all web sites and not just your internal one.