I am facing some issue with JS function to open a popup window.
It is working fine when i open the parent screen in a new window.
but when the parent folder is being used in some other page under tabpanel, then the window.open is giving object required error.
////JS function////
function popupDecline()
{
var window_width = 1270;
var window_height = 945;
var window_left = 1270-(window_width/1);
var window_top = 945-(window_height/1);
var winParms = "Status=yes" + ",resizable=yes" + ",height="+window_height+",width="+window_width + ",left="+window_left+",top="+window_top;
newwindow = window.open('child.seam','_blank',winParms);
newwindow.focus()
}
////richfaces where i am calling the parent xhtml////////////
<rich:panel>
<rich:tabPanel headerAlignment="left" switchType="server" width="100%" activeTabClass="activeTab"
inactiveTabClass="inactiveTab" tabClass="TabClass">
<rich:tab label="parent" action="#{breadCrumbBean.tabAction}" >
<f:param name="param1" value="1"/>
<ui:include src="./parent.xhtml" />
</rich:tab>
when i looked into it the line "newwindow = window.open('child.seam','_blank',winParms);" is causing the error.
I guess nothing wrong whith this JS function since it is working fine in other pages too as well as in these pages.
I am not getting why on this earth it is behaving so indifferently
Somebody please provide me the solution. I need it very urgently and very badly.
Thanks in advance!