Open a window and resize in JavaScript
Description
The following code shows how to open a window and resize.
Example
<!-- ww w . j a v a 2 s . c o m-->
<!DOCTYPE HTML>
<html>
<body>
<script type="text/javascript">
var java2sWin =window.open("http://www.java2s.com/","myWindow");
java2sWin.resizeTo(500, 500);
java2sWin.moveTo(100, 100);
</script>
</body>
</html>
The code above generates the following result.
Javascript Tutorial Browser Window
Access the window owner through opener prop...
Add link and open new windows after clickin...
Check the visibility of menubar, toolbar, l...
Close a window in JavaScript
Close the newly opened window by calling th...
Create a new window and add form controls i...
Get the current URL of the document in the ...
Get window location on the screen in Javasc...
Get window name specified when new windows ...
Get window size, width, height in JavaScrip...
Move a window by 100 pixels in JavaScript
Move a window to a new location in JavaScri...
Move window to the left in JavaScript
Open a new window in JavaScript
Resize a window in JavaScript
Scroll a window in Javascript in JavaScript
Set URL location for a window in JavaScript
Tell if a pop-up was blocked by checking th...
Use focus() method places focus on the wind...
Use frames property to access frame instanc...
Use window.frames["frameName"].length in Ja...
Use window.onscroll to add the onscroll eve...
Access the window owner through opener prop...
Add link and open new windows after clickin...
Check the visibility of menubar, toolbar, l...
Close a window in JavaScript
Close the newly opened window by calling th...
Create a new window and add form controls i...
Get the current URL of the document in the ...
Get window location on the screen in Javasc...
Get window name specified when new windows ...
Get window size, width, height in JavaScrip...
Move a window by 100 pixels in JavaScript
Move a window to a new location in JavaScri...
Move window to the left in JavaScript
Open a new window in JavaScript
Open a window and resize in JavaScript
Open new window and set window location in ...Resize a window in JavaScript
Scroll a window in Javascript in JavaScript
Set URL location for a window in JavaScript
Tell if a pop-up was blocked by checking th...
Use focus() method places focus on the wind...
Use frames property to access frame instanc...
Use window.frames["frameName"].length in Ja...
Use window.onscroll to add the onscroll eve...