RE: [INTERNALS-WIN] STDIN missing.

From: Date: Tue, 25 Aug 2009 21:03:21 +0000
Subject: RE: [INTERNALS-WIN] STDIN missing.
References: 1 2 3 4  Groups: php.internals.win 
Request: Send a blank email to internals-win+get-578@lists.php.net to get a copy of this message
I just installed PHP using the installer (something I can't ever recall doing before ;) ) I enabled the "Script Executable" and it's child "Register *.php files to open automatically with PHP") options. This apparently sets the handler for .PHP scripts to php-win.exe (which is a GUI process, not a console one) so I assume this is the process you see in the task manager. This would need to be set to php.exe for the script to work correctly. From your example, I can't see how: C:\Scripts\Reverse Would even run the script, from the install of PHP, it doesn't appear that the PATHEXT environment variable is modified so that .PHP is a recognized extension for executables. In the event that you actually meant: C:\Scripts\Reverse.php That would indeed invoke php-win.exe, but doesn't wait (again, because it's using the GUI version of PHP). When you use: DIR C:\ | C:\PHP5\php.exe C:\Scripts\Reverse.php You are explicity using the cmdline version of PHP, which is why it works. If you want to set the command line version of PHP as the default, you can change the registry key that points to the version of PHP you want to use. Use the reg.exe tool to check the settings, and change it. First: C:\> reg query HKEY_CLASSES_ROOT\.php Will display something like: HKEY_CLASSES_ROOT\.php (Default) REG_SZ PHPFile Content Type REG_SZ application/php Look at the (Default) and use that to look up the installed handler for PHP: reg query HKEY_CLASSES_ROOT\PHPFile\shell\open\command ('PHPFile' may be different depending on what tools you may have installed.) This displays: HKEY_CLASSES_ROOT\PHPFile\shell\open\command (Default) REG_SZ C:\PROGRA~1\PHP\php-win.exe "%1" To Change the setting: reg add HKEY_CLASSES_ROOT\PHPFile\shell\open\command /ve /t REG_SZ /d "c:\php\php.exe" /f Where 'c:\php\php.exe' is the path to PHP you want to have enabled. G -----Original Message----- From: parasane@gmail.com [mailto:parasane@gmail.com] On Behalf Of Daniel Brown Sent: Tuesday, August 25, 2009 12:49 PM To: RQuadling@googlemail.com Cc: Pierre Joye; internals-win@lists.php.net Subject: Re: [INTERNALS-WIN] STDIN missing. On Tue, Aug 25, 2009 at 14:56, Richard Quadling<rquadling@googlemail.com> wrote: > > I wish I could talk to someone at MS, just to know what is going on. > But I'm a LONG way down the food chain for that. Indeed. If only we knew *someone* who worked for Microsoft.... ;-P -- </Daniel P. Brown> daniel.brown@parasane.net || danbrown@php.net http://www.parasane.net/ || http://www.pilotpig.net/ Check out our great hosting and dedicated server deals at http://twitter.com/pilotpig -- Windows Internals Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.internals.win (#578) next »