Win a copy of Learning OpenStack Networking: Build a solid foundation in virtual networking technologies for OpenStack-based clouds this week in the Cloud/Virtualization forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Ganesh Patekar
  • Stephan van Hulst
  • Pete Letkeman
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Ron McLeod
  • Vijitha Kumara

JavaScript Window Open  RSS feed

 
Ranch Hand
Posts: 492
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

I just want to open a window with full size I mean fit to maximized size. I tried with the code but it's opening in the size 800 X 600(I hard codded). I need it in 100% X 100%. Please assit me.

window.open('b.html','popUpWindow','width=800,height=600,left=0,top=0,status=no,toolbar=no,location=no,menubar=no,titlebar=no');

Not working
window.open('b.html','popUpWindow','width=100%,height=100%,left=0,top=0,status=no,toolbar=no,location=no,menubar=no,titlebar=no');
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try this:

window.open('b.html','popUpWindow','fullscreen,scrollbars,resizable,toolbar,menubar,location,status');

This should mimic a maximized browser in both Internet Explorer and Firefox.
 
Meet Gaurav
Ranch Hand
Posts: 492
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I slightly altered the code after that it's working fine in Firefox but not in IE.


In IE it's opening a window in fullsize(Even not able to see the titlebar close button)
 
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Look into window.open screen.availwidth

Eric
 
Nathan Hiemenz
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Meet Gaurav wrote:I slightly altered the code after that it's working fine in Firefox but not in IE.


In IE it's opening a window in fullsize(Even not able to see the titlebar close button)



This is in interesting nuance of IE. In local code (eg if you run the file from your harddrive) the code snippet I gave will open the window as a literal fullscreen (no menu, nothing), but do to the security settings for "web" code, if you upload the piece to a website and run it, it will open in a new window like normal. Here's an example:

http://www.realmprotectors.com/testy.html

View the source and it's the same I gave you (possibly in a different order).
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!