Window.open Help
-
Hi, I have an application that uses frames. I am calling a method in parent frame as below.(below method is in child frame) function my MyChild() { var pth = window.location.href; //http://localhost/Main/SUB/Child.aspx[^] parent.frames["MainFrame"].MainMethod(); } below is my function in parent Frame, and I am trying to open a new window but that is opening new page in child location I am using below code , is ter any way so that I can track the URL it is trying to open. function MainMethod() { var path=window.location.href; //below is the value //http://localhost/Main/Parent.aspx[^] window.open("Newpage.aspx"); //it is opening in http://localhost/Main/SUB/NewPage.aspx[^] But I am expecting it will open in http://localhost/Main/NewPage.aspx[^] } Please suggest how Can i get the URl path it is trying to open, since window.location.href is giving differnt value. Thanks,
-
Hi, I have an application that uses frames. I am calling a method in parent frame as below.(below method is in child frame) function my MyChild() { var pth = window.location.href; //http://localhost/Main/SUB/Child.aspx[^] parent.frames["MainFrame"].MainMethod(); } below is my function in parent Frame, and I am trying to open a new window but that is opening new page in child location I am using below code , is ter any way so that I can track the URL it is trying to open. function MainMethod() { var path=window.location.href; //below is the value //http://localhost/Main/Parent.aspx[^] window.open("Newpage.aspx"); //it is opening in http://localhost/Main/SUB/NewPage.aspx[^] But I am expecting it will open in http://localhost/Main/NewPage.aspx[^] } Please suggest how Can i get the URl path it is trying to open, since window.location.href is giving differnt value. Thanks,