MaGiCSuN
June 26th, 2001, 08:20
ok, i need this for a pop-up to make
my screen size is 800x900
and i've got the adresfield in it and the standardbuttons on the top and in the bottom there's the statusthing, or something
now i have to know, what's the size of the page that opens in it ? (i need only the size of the page, not of the standardbuttons and stuff with it )
Thnxx !!
Love,
Mirna
lucifer
June 26th, 2001, 08:58
??
what exactlly do you mean?
the size of the window opening the pop-up shouldn't be important
MaGiCSuN
June 26th, 2001, 09:04
yes it is, because i've got a layout, and that fit exactly in the normal screen, but the girl that has this layout want it to be a pop-up
lucifer
June 26th, 2001, 09:20
it is irrelevant to the pop-up
window.open()
Opens a new web browser window.Method of
window
Implemented in
JavaScript 1.0
JavaScript 1.2: added several new windowFeatures
Syntax
open(URL, windowName[, windowFeatures])
Parameters
URL
A string specifying the URL to open in the new window. See the Location object for a description of the URL components.
windowName
A string specifying the window name to use in the TARGET attribute of a FORM or A tag. windowName can contain only alphanumeric or underscore (_) characters.
windowFeatures
A string containing a comma-separated list determining whether or not to create various standard window features. These options are described in the following section.
Description
In event handlers, you must specify window.open() instead of simply using open(). Due to the scoping of static objects in JavaScript, a call to open() without specifying an object name is equivalent to document.open().
The open method opens a new Web browser window on the client, similar to choosing New, then Navigator Window from the Navigator File menu. The URL argument specifies the URL contained by the new window. If URL is an empty string, a new, empty window is created.
You can use open on an existing window, and if you pass the empty string for the URL, you will get a reference to the existing window, but not load anything into it. You can, for example, then look for properties in the window.
windowFeatures is an optional string containing a comma-separated list of options for the new window (do not include any spaces in this list). After a window is open, you cannot use JavaScript to change the windowFeatures. You can specify the following features:
Table 1.4 Optional features to specify for a new window. windowFeatures Description
alwaysLowered
(JavaScript 1.2) If yes, creates a new window that floats below other windows, whether it is active or not. This is a secure feature and must be set in signed scripts.
alwaysRaised
(JavaScript 1.2) If yes, creates a new window that floats on top of other windows, whether it is active or not. This is a secure feature and must be set in signed scripts.
dependent
(JavaScript 1.2) If yes, creates a new window as a child of the current window. A dependent window closes when its parent window closes. On Windows platforms, a dependent window does not show on the task bar.
directories
If yes, creates the standard browser directory buttons, such as What's New and What's Cool.
height
(JavaScript 1.0 and 1.1) Specifies the height of the window in pixels.
hotkeys
(JavaScript 1.2) If no (or 0), disables most hotkeys in a new window that has no menu bar. The security and quit hotkeys remain enabled.
innerHeight
(JavaScript 1.2) Specifies the height, in pixels, of the window's content area. To create a window smaller than 100 x 100 pixels, set this feature in a signed script. This feature replaces height, which remains for backwards compatibility.
innerWidth
(JavaScript 1.2) Specifies the width, in pixels, of the window's content area. To create a window smaller than 100 x 100 pixels, set this feature in a signed script. This feature replaces width, which remains for backwards compatibility.
location
If yes, creates a Location entry field.
menubar
If yes, creates the menu at the top of the window.
outerHeight
(JavaScript 1.2) Specifies the vertical dimension, in pixels, of the outside boundary of the window. To create a window smaller than 100 x 100 pixels, set this feature in a signed script.
personalbar
(JavaScript 1.2) If yes, creates the Personal Toolbar, which displays buttons from the user's Personal Toolbar bookmark folder.
resizable
If yes, allows a user to resize the window.
screenX
(JavaScript 1.2) Specifies the distance the new window is placed from the left side of the screen. To place a window offscreen, set this feature in a signed scripts.
screenY
(JavaScript 1.2) Specifies the distance the new window is placed from the top of the screen. To place a window offscreen, set this feature in a signed scripts.
scrollbars
If yes, creates horizontal and vertical scrollbars when the Document grows larger than the window dimensions.
status
If yes, creates the status bar at the bottom of the window.
titlebar
(JavaScript 1.2) If yes, creates a window with a title bar. To set the titlebar to no, set this feature in a signed script.
toolbar
If yes, creates the standard browser toolbar, with buttons such as Back and Forward.
width
(JavaScript 1.0 and 1.1) Specifies the width of the window in pixels.
z-lock
(JavaScript 1.2) If yes, creates a new window that does not rise above other windows when activated. This is a secure feature and must be set in signed scripts.
Many of these features (as noted above) can either be yes or no. For these features, you can use 1 instead of yes and 0 instead of no. If you want to turn a feature on, you can also simply list the feature name in the windowFeatures string.
If windowName does not specify an existing window and you do not supply the windowFeatures parameter, all of the features which have a yes/no choice are yes by default. However, if you do supply the windowFeatures parameter, then the titlebar and hotkeys are still yes by default, but the other features which have a yes/no choice are no by default.
For example, all of the following statements turn on the toolbar option and turn off all other Boolean options:
open("", "messageWindow", "toolbar")open("", "messageWindow", "toolbar=yes")open("", "messageWindow", "toolbar=1")
The following statement turn on the location and directories options and turns off all other Boolean options:
open("", "messageWindow", "toolbar,directories=yes")
How the alwaysLowered, alwaysRaised, and z-lock features behave depends on the windowing hierarchy of the platform. For example, on Windows, an alwaysLowered or z-locked browser window is below all windows in all open applications. On Macintosh, an alwaysLowered browser window is below all browser windows, but not necessarily below windows in other open applications. Similarly for an alwaysRaised window.
You may use open to open a new window and then use open on that window to open another window, and so on. In this way, you can end up with a chain of opened windows, each of which has an opener property pointing to the window that opened it.
Communicator allows a maximum of 100 windows to be around at once. If you open window2 from window1 and then are done with window1, be sure to set the opener property of window2 to null. This allows JavaScript to garbage collect window1. If you do not set the opener property to null, the window1 object remains, even though it's no longer really needed.
Security
To perform the following operations, you need the UniversalBrowserWrite privilege:
To create a window smaller than 100 x 100 pixels or larger than the screen can accommodate by using innerWidth, innerHeight, outerWidth, and outerHeight.
To place a window off screen by using screenX and screenY.
To create a window without a titlebar by using titlebar.
To use alwaysRaised, alwaysLowered, or z-lock for any setting.
For information on security, see the Client-Side JavaScript Guide.
meow
June 27th, 2001, 23:01
Originally posted by MaGiCSuN
yes it is, because i've got a layout, and that fit exactly in the normal screen, but the girl that has this layout want it to be a pop-up
I think you have misunderstood the concept of "size" here. What pixel size your screen has is of no relevance if you want others to be able to see the page in a comfortable way. If you make a pop-up (or any page for that matter) that is fixed size and larger than the smallest screen you want to accommodate, it will be very uncomfortable to view. You simply can't make pages that fits only your screen and your settings. Oh, you can, but you shouldn't. ;)
I don't know, maybe you rather mean you want the page to open in a new window? If so just add target="_blank" to the link.
<a href="nextpage.html" target="_blank">
Sorry if I misunderstand what you want to do.:)
Powered by vBulletin® Version 4.1.7 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.