|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2003-03-12 11:33 UTC] pjaleysen at hotmail dot com
Hi, shell_exec(),as well as exec(),system(), can only handle 'native' DOS applications like ping,copy,attrib etc. either directly as a command, or though a *.bat file. Executing other (DOS) applications like pkzip (for DOS) or (rar for dos) don't seem to work. There is a thread of this issue at www.devshed.com (http://forums.devshed.com/t55038/s.html) I am using: -Windows XP -Apache 1.3.27 -PHP4.3 All with the default configurations. Kind regards Patrick PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Nov 03 03:00:01 2025 UTC |
How are you passing your params to shell_exec() ? I know from personal experience, that shell_exec() requires me to load command.com to the interpreter, such as: print shell_exec('cmd version'); This *should* print out your windows version... ~ Andrew HeebnerSorry, that should be shell_exec('cmd ver'); ~ Andrew HeebnerCan someone tell me why the following code will not work in Windows: system("nmap $host"); Driving me nuts. It works fine on apache servers and apparantly other IIS servers. I don't know if i'm missing something in php.ini or what. Other commands can be run from system(), just not nmap.