Fw: start an external program (isqlw.exe)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



You can start certain programms at the client side using COM. But
(unfortunately ?) only when using PHP on windows webservers. Programm should
be installed at client side off course. But I do agree with Frank.
----- Original Message ----- 
From: "Frank M. Kromann" <frank@xxxxxxxxxxxx>
To: "Gerardo Rojas" <grojas@xxxxxxxxxxxxxxxx>
Cc: "Gerardo Rojas" <grojas@xxxxxxxxxxxxxxxx>; "Svensson, B.A.T. (HKG)"
<b.a.t.svensson@xxxxxxx>; <php-windows@xxxxxxxxxxxxx>
Sent: Wednesday, March 03, 2004 7:24 PM
Subject: RE:  start an external program (isqlw.exe)


> The answer is no (unless the client and server is running on the same
> bos).
>
> PHP is a server side scripting language and the only information send to
> the client is through the HTTP protocol. Cold you imaginne what would
> happen if a web server could start programs on the client maschine?
>
> - Frank
>
> > Got this to work, but my problem now is that this will only open windows
> on the machine hosting the WebServer, is there a way to open an
> application on the client side?
> >
> > also had to make some changes to IIS.  Logon Tab, check the box where it
> says "allow service to interact with desktop"
> >
> > my code goes here
> > -----------------------------------------------
> > $ip = $_SERVER['QUERY_STRING'];
> >
> > $program = "start \"Query Analyzer\" /D\"c:\\Program Files\\Microsoft
> SQL Server\\80\\Tools\\binn\" /NORMAL isqlw.exe -S$ip -Umyuserid
> -Pmypassword";
> > $aOutput = array();
> > $retval = 0;
> > echo "<br>program = $program";
> >
> > exec($program, $aOutput, $retval);
> > foreach($aOutput as $val )
> > {
> > echo "<br>value = $val";
> > }
> > echo "<br>Dumping retval = $retval";
> >
> > -------------------------------------------------
> >
> >
> > --
> > Gerardo S. Rojas
> > mailto: grojas@xxxxxxxxxxxxxxxx
> >
> >
> > -----Original Message-----
> > From: Gerardo Rojas [mailto:grojas@xxxxxxxxxxxxxxxx]
> > Sent: Tuesday, March 02, 2004 11:36 AM
> > To: Svensson, B.A.T. (HKG); php-windows@xxxxxxxxxxxxx
> > Subject: RE:  start an external program (isqlw.exe)
> >
> >
> > No, the "isqlw.exe" is the full SQL Query Analyzer tool.  I have the
> full path and executable name.  I just don't know how to call it (exactly)
> from within PHP.
> >
> >
> > --
> > Gerardo S. Rojas
> > mailto: grojas@xxxxxxxxxxxxxxxx
> >
> >
> > -----Original Message-----
> > From: Svensson, B.A.T. (HKG) [mailto:B.A.T.Svensson@xxxxxxx]
> > Sent: Tuesday, March 02, 2004 11:31 AM
> > To: php-windows@xxxxxxxxxxxxx
> > Subject: RE:  start an external program (isqlw.exe)
> >
> >
> > For system(), etc , you need executable right for the default command
> > shell, and you might like to do "start isql.exe ..." besides, you might
> > also need to include the full path(??).
> >
> > There are some other function calls that also might be better suited to
> > fork with... but let me have a check tomorrow (time to leave work)
> >
> > Anyhow, isqlw.exe, isn't that the plain windows version of isql.exe,
> > i.e. /not/ the analyzer but the simplified version of it?
> >
> > On Tue, 2004-03-02 at 18:25, Gerardo Rojas wrote:
> > > the executable is "isqlw.exe" the arguments are -S server -U userid -P
> password.
> > >
> > >
> > > --
> > > Gerardo S. Rojas
> > > mailto: grojas@xxxxxxxxxxxxxxxx
> > >
> > >
> > > -----Original Message-----
> > > From: Svensson, B.A.T. (HKG) [mailto:B.A.T.Svensson@xxxxxxx]
> > > Sent: Tuesday, March 02, 2004 11:23 AM
> > > To: php-windows@xxxxxxxxxxxxx
> > > Subject: RE:  start an external program (isqlw.exe)
> > >
> > >
> > > Aha, that makes sense! :)
> > >
> > > Very well, anyway.. .from time to time I tried to locate the
> executable
> > > for this, but failed (could not identify it in "$MSSQL_HOME\binn". I
> > > also been way to lazy with this (no urgent need as to say). Maybe to
> > > check the properties of start menu item will help(?), but am not so
> sure
> > > about that...
> > >
> > > In any case, if you find out, would you please save me some time as
> well
> > > and let me know?
> > >
> > > On Tue, 2004-03-02 at 18:17, Gerardo Rojas wrote:
> > > > I have many different SQL Servers that i connect to.  This way with
> PHP (webserver) i can generate a list and quickly pick the one I want and
> connect to it (also passing the userid and password, this seems like a
> faster way to do it)
> > > >
> > > >
> > > > --
> > > > Gerardo S. Rojas
> > > > mailto: grojas@xxxxxxxxxxxxxxxx
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: Svensson, B.A.T. (HKG) [mailto:B.A.T.Svensson@xxxxxxx]
> > > > Sent: Tuesday, March 02, 2004 11:14 AM
> > > > To: php-windows@xxxxxxxxxxxxx
> > > > Subject: Re:  start an external program (isqlw.exe)
> > > >
> > > >
> > > > Why the do you want to do this with php????
> > > >
> > > >
> > > > On Tue, 2004-03-02 at 17:29, Gerardo Rojas wrote:
> > > > > Is there a quick way to start the "Query Analyzer" from within
> PHP?
> > > > > I've tried exec() and system() with no success.
> > > > >
> > > > >
> > > > > --
> > > > > Gerardo S. Rojas
> > > > > mailto: grojas@xxxxxxxxxxxxxxxx
> > > > >
> >
> > -- 
> > PHP Windows Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> > -- 
> > PHP Windows Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> > --
> > PHP Windows Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
>
> -- 
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>

-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Database Programming]     [PHP Install]     [Kernel Newbies]     [Yosemite Forum]     [PHP Books]

  Powered by Linux