Open Window of specific size

  • ThePriv
  • Novice
  • Novice
  • ThePriv
  • Posts: 17

Post 3+ Months Ago

I want to open a new window in a specific size-- (but NOT a pop-up.)

I am using Homestead.com as my web hosting company, and everything is quite simple to arrange, create, etc.

I have a clickable button that opens a new browser window for a (real estate) calculator, and I need ONLY a window about half the size of the full screen--which is what opens every time (full screen). is there some way to make the new window say, 400X500?

Thanx!

the link to open is: http://clientdirect.net/news/est_payments.htm
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

There's a variety of ways to do it several of which are included in this link

http://www.java2s.com/Code/JavaScript/W ... sition.htm
  • ThePriv
  • Novice
  • Novice
  • ThePriv
  • Posts: 17

Post 3+ Months Ago

Hmmm.
Thanx. But I'm a little unsure how to apply it to my web page.

I have an option to make a window with HTML code...but it isn't creating a button to click.
  • ThePriv
  • Novice
  • Novice
  • ThePriv
  • Posts: 17

Post 3+ Months Ago

AH!

Got it!

Thanx!
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

Well if you take the example in the link I posted this part in the <head> tags is the javascript that defines the properties for the window

Code: [ Select ]
<SCRIPT language="JavaScript">
<!--
function new_win()
{
    window.open("http://www.java2s.com","mywin","width=400,height=300,screenX=50,left=50,screenY=50,top=50,status=yes,menubar=yes");
}
 
//-->
</SCRIPT>
  1. <SCRIPT language="JavaScript">
  2. <!--
  3. function new_win()
  4. {
  5.     window.open("http://www.java2s.com","mywin","width=400,height=300,screenX=50,left=50,screenY=50,top=50,status=yes,menubar=yes");
  6. }
  7.  
  8. //-->
  9. </SCRIPT>


Then in the body, this is the part that creates the button to click (you would put this code wherever you want your button)
Code: [ Select ]
<FORM name="myform">
<INPUT TYPE="button" value="Open New Window" onClick="new_win()">
</FORM>
  1. <FORM name="myform">
  2. <INPUT TYPE="button" value="Open New Window" onClick="new_win()">
  3. </FORM>
  • ThePriv
  • Novice
  • Novice
  • ThePriv
  • Posts: 17

Post 3+ Months Ago

How can I change the look of the button? Kinda fugly. I have a small jpg of a calculator that I'd rather have.

Thanx!
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

You can apply style to it with CSS.

http://www.webreference.com/programming/css_stylish/

Or you could use a graphic image you've created for your button.
http://bignosebird.com/docs/h41.shtml
  • ThePriv
  • Novice
  • Novice
  • ThePriv
  • Posts: 17

Post 3+ Months Ago

whoa..
This stuff is way too complicated for me.
Ugh.

Many thanx for your help.
  • ThePriv
  • Novice
  • Novice
  • ThePriv
  • Posts: 17

Post 3+ Months Ago

Just another thanx.
I played around with it, and finally figured it out.
Got it!

Thank you.
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

you're welcome
  • ThePriv
  • Novice
  • Novice
  • ThePriv
  • Posts: 17

Post 3+ Months Ago

FYI
I opened a new topic as I discovered that in IE7 the window opens FULLY. In Firefox it opens according to the instructions of 600x700.
I included the code.

The topic header is:
"Back to the SPECIFIC SIZE Board"
  • clemsondjm
  • Born
  • Born
  • clemsondjm
  • Posts: 1

Post 3+ Months Ago

I was hoping you (ATNO/TW) could also help me. I have a similar question. I am writing a page for my churches website that has a layout picture of the grounds and I am putting Hotspots on top of various buildings in the picture so I can hyperlink them to a new page that show a picture of the building or area with a small description. I to want to open small window with no controls ontop of the current open window. I have tried to apply what you noted in this blog with no success. The page in question if you want to take a look is http://www.fpcandersonsc.com/FPC-Campus_Layout.html. Any help you can give me is great. PS: I am using Microsoft Expression Web to write this page. The page is in HTML.
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

I'll try to take a look when I can but may not be until this weekend. Others here tho are quite familiar with this kind of thing and may be able to give advice before I can.

Post Information

  • Total Posts in this topic: 13 posts
  • Users browsing this forum: No registered users and 58 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.