[[php_dhtml:window_properties]]
 

Window properties

Using dhtml_get and dhtml_set you can get or set dhtml window properties.

name set get parameters explanation
Window control
show X Show the window to the user
hide X Hide (totaly) the window
minimize X Hide the window but let a button on the task bar
maximize X Maximize th size of the window
restore X Restore a window to it’s previous state
title X X string $title Change the window title1)
size X string {size_x}x{size_y} Change the size of the window
move X string {size_x}x{size_y} Move the window
close X Close the window, a closed window is then destroyed2)
timer X int timer_id, int sec Timer timeout, use 0 to ‘kill’ the timer
quit X Exit the thread (emergency, it’s better to use close3))
focus X Bring window to top
Browser control
url X X string url Load an url or a file
reload X Reload current page
Look
3d_look X string on 0/off⇒off ~ ⇒ on
scrollbar X string type 0/off ⇒ off<br>1/on ⇒ on<br>flat ⇒ flat scroll bar

FIXME Add missing properties

Exemple

dhtml_set($wnd, "show",  "1");
dhtml_set($wnd, "size", "640x480");
dhtml_set($wnd, "title", "An exemple");
dhtml_set($wnd, "url", "file://".realpath($myHtmlPage)); // realpath *is* important
1) The HTML/HEAD/TITLE element of the current file is never used
2) Once closed you can’t use it anymore
3) Since you can leak memory
 
  php_dhtml/window_properties.txt · Last modified: 2004/11/21 18:20
 
Recent changes RSS feed Powered by PHP Driven by DokuWiki