Click here to Skip to main content
15,895,772 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi guys ,
when I redirect to website that should open in new window of particular size,

I am Accessing my website from other website ,when I click button in other website open my website in small window ,,

I have tried but i am not getting guys please help me ,

Please help me how t do .

thanks ,
mani
Posted
Comments
Kornfeld Eliyahu Peter 3-Jun-15 6:39am    
Please show the code you used to open the new window...form there we may help you...
u mani 3-Jun-15 6:42am    
<script language="javascript" type="text/javascript">

var win = null;
function NewWindow(mypage, myname, w, h, scroll, pos) {
if (pos == "random") { LeftPosition = (screen.width) ? Math.floor(Math.random() * (screen.width - w)) : 100; TopPosition = (screen.height) ? Math.floor(Math.random() * ((screen.height - h) - 75)) : 100; }
if (pos == "center") { LeftPosition = (screen.width) ? (screen.width - w) / 2 : 100; TopPosition = (screen.height) ? (screen.height - h) / 2 : 100; }
else if ((pos != "center" && pos != "random") || pos == null) { LeftPosition = 0; TopPosition = 20 }
settings = 'width=' + w + ',height=' + h + ',top=' + TopPosition + ',left=' + LeftPosition + ',scrollbars=' + scroll + ',location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=no';
win = window.open(mypage, myname, settings);
}

</script>


YourLinkText



this code i have used , but when i open one page it should be in new window ,please tell me how to do
Kornfeld Eliyahu Peter 3-Jun-15 6:43am    
Please add it to your question (Improve question) and format it to help us read it...
u mani 3-Jun-15 6:44am    
otherwise i open perticular page it should be open in new window of particular size
ZurdoDev 3-Jun-15 7:39am    
window.open() is the way to do it. So, what is the problem?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900