Voting

: min(one, one)?
(Example: nine)

The Note You're Voting On

lc at _REMOVE__THIS_lc dot yi dot org
21 years ago
Re: cpmorris at hotmail dot com and WINNT.

I just spent some time learning to use the php system function. I managed to get long file names to work for me. It seems you need to take the same approach that batch files, WSH, and most other programming languages do under WinNT/2K/XP. Putting double quotes around the Path+Filename seems to work. So, something like this should have worked for you:

"c:\program files\apache group\apache2\bin\htpasswd"

Note that if you have parameters, they go OUTSIDE of the last quote. Oh, and don't forget to escape the slashes and quotes!

I don't know what htpasswd's params are, but let us pretend:

$cmd="\"c:\\program files\\apache group\\apache2\\bin\\htpasswd\" username password";
$str=system($cmd);

Hope this helps someone!

Leonard
http:\\www.lc.yi.org

<< Back to user notes page

To Top