[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1467
  • Last Modified:

How do you Maximize a Web Page in HTML?

Hello-  I have a hyperlink on my web page that opens another web page when clicked.  When that hyper is clicked the correct web page opens but is not maximized by default.  What can I add to my HTML or javascript code to have that page open Maximized?

Thanks.
0
JoshinHtown
Asked:
JoshinHtown
  • 4
  • 2
1 Solution
 
b0lsc0ttCommented:
JoshinHtown,

HTML can't, it just opens the new window as the same size as the current one, but Javascript can help.  You would use window.open.  The "maximize" option is no longer well supported so you should specify a size too.  For example ...

<a href="#" onclick="window.open('http://thedomain.com/page.htm', 'windowName', 'height=600,width=800,fullscreen=yes');">Open window</a>

You can specify the URL, the window name (which is used by the script) and the features.

Let me know if you have any questions or need more information.

b0lsc0tt
0
 
b0lsc0ttCommented:
You can get more info on window.open at http://www.devguru.com/Technologies/ecmaScript/quickref/win_open.html.

bol
0
 
JoshinHtownAuthor Commented:
Hello b0lscott-

I tried this code below for my hyperlink but nothing happens when I click it at runtime.  What am I missing?  Regards,

<area href="#" onclick="window.open('www.yahoo.com, 'Yahoo Site', 'height=600,width=800,fullscreen=yes');"></a>
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
b0lsc0ttCommented:
There are just some small errors.

<a href="#" onclick="window.open('http://www.yahoo.com', 'YahooSite', 'height=600,width=800,fullscreen=yes');">Link</a>

That should work.

bol
0
 
JoshinHtownAuthor Commented:
Great. Thanks
0
 
b0lsc0ttCommented:
Your welcome!  I'm glad I could help.  Thanks for the grade, the points and the fun question.

bol
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now