FRIHOSTFORUMSFAQTOSBLOGSDIRECTORY
You are invited to Log in or Register a Frihost Account!

how do I retrict resize and restore with javascript?

 


game_dev
Hi,

Someone happens to have a javascript snippet that:


1) upon window restore operation (after a maximize , for instance) , , will restore to a fixed size ( say 200x200 ) and NOT to latest user defined size?

2) upon manual resize of the window, will not let it go smaller than a fixed size ( say 200x200 )

Thanks in advance,

gd
LukeakaDanish
easy...

When you open the window, use the following code:

Code:

newWin = window.open('location','window_name','height=200, width=200, resizeable=no');


...of course modifying the "location" and "window_name" attributes.

This page: http://www.pageresource.com/jscript/jwinopen.htm details opening windows with javascript pretty well.
game_dev
Thanks for the reply but this is not what I want. Confused

This post of yours created an unresizable window, but I want the window to be resizable by user, only that when they are resizing and restoring some restrictions will aply, but they can still resize it , maximize it and restore it.

The code I'm looking would use most probably use javascript event callbacks.
Reply to topic    Frihost Forum Index -> Scripting -> Html, CSS and Javascript

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2007 Frihost, forums powered by phpBB.