This is a discussion on using php to open a broswer? within the alt.comp.lang.php forums, part of the PHP Programming Forums category; hi how can u i use php to open a browser and display somthing? am developing an application i want ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Sunusi Ringim wrote:
> hi > how can u i use php to open a browser and display somthing? am > developing an application i want to uweb GUI. please help. Indeed. If a browser is installed on the server, you can simply open a browser window with exec(). Check the command line options of that browser to open a certain page. Given enough rights, PHP will happily open a browserwindow for you on the server. If you mean that a window has to be opened by a remote client on a request: not possible with PHP. -- Grtz, Rik Wasmus |
|
|||
|
It might not be possible directly through PHP, but it is possible
indirectly. <? function openwindow($url, $title = "MyWindow", $width = 400, $height = 200) { ?><script language="javascript" type="text/javascript"> window.open('<?= $url ?>','<?= title ?>','width=<?= $width ?>,height=<?= $height ?>); </script> <? exit; } ?> PHP May be server side, but it writes all the content that is seen by the user, so it is in effect, controlling the js. Rik wrote: > Sunusi Ringim wrote: > > hi > > how can u i use php to open a browser and display somthing? am > > developing an application i want to uweb GUI. please help. > > Indeed. If a browser is installed on the server, you can simply open a > browser window with exec(). Check the command line options of that browser > to open a certain page. Given enough rights, PHP will happily open a > browserwindow for you on the server. > > If you mean that a window has to be opened by a remote client on a request: > not possible with PHP. > > -- > Grtz, > > Rik Wasmus |