I would try something like this instead: $params = escapeshellarg($params); $output = system(c:\path\to\htpasswd $params); //check for output errors or what not
There very well could be a better solution (especially since I have not tried the above code...). I remember seeing somewhere that the crypt algorithms are different for Apache and PHP on Win32. -Dash Cleanliness is next to impossible. On Tue, 28 Jan 2003, Dominik Wittenbeck wrote: > I am currently trying to create a .htpasswd file for apache using PHP and > the crypt() on Win2k. I can generate the file alright but it does not work. > I have looked into some classes as well and all use the crypt() function. > The reason for this not working is probably the algorithm used because the > passwords within a .htpasswd created with apache looks a hell lot different > using something like > > $apr1$rB2.....$8iUWArWEsTQ2553kjk22NS1 (not a real password by the way) > > anyone having experience with that? Something up because I use windows? > > Dominik Wittenbeck > ---------------------------------------------------------------- > E-Mail: [EMAIL PROTECTED] > URL: http://www.developaz.com > > > > -- > 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