View Single Post
  #2 (permalink)  
Old 04-30-2008, 11:44 AM
DonCash's Avatar
DonCash DonCash is offline
Moderator
 
Join Date: Aug 2007
Location: London, UK
Posts: 239
DonCash will become famous soon enoughDonCash will become famous soon enough
Hello Lilith2014.

These forums are for Java questions. JavaScript is actually a completely different language.

I suggest you search google for a dedicated JavaScript forum. You will find a lot more help there than here!

Another google search revealed this:

Code:
<SCRIPT LANGUAGE="JavaScript"> function MyPopUpWin() { var iMyWidth; var iMyHeight; //half the screen width minus half the new window width (plus 5 pixel borders). iMyWidth = (window.screen.width/2) - (75 + 10); //half the screen height minus half the new window height (plus title and status bars). iMyHeight = (window.screen.height/2) - (100 + 50); //Open the window. var win2 = window.open("filename.htm","Window2","status=no,height=200,width=150,resizable=yes,left=" + iMyWidth + ",top=" + iMyHeight + ",screenX=" + iMyWidth + ",screenY=" + iMyHeight + ",toolbar=no,menubar=no,scrollbars=no,location=no,directories=no"); win2.focus(); } </SCRIPT>
To call this function in HTML use this:

Code:
<A HREF="javascript:MyPopUpWin()">This is the link</a>
__________________
Did this post help you? Please
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
me!

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

Last edited by DonCash : 04-30-2008 at 11:48 AM.
Reply With Quote