If the code like this,it's ok
header("Cache-Control:no-cache,must-revalidate");
$handle = popen('svn --version','r');
$read = stream_get_contents($handle);
echo "<pre>";
printf($read);
echo "</pre>";
pclose($handle);
that's OK. output:
svn, version 1.6.11 (r934486) compiled Apr 11 2013, 16:13:51
Copyright (C) 2000-2009 CollabNet. Subversion is open source software,
see http://subversion.tigris.org/ This product includes software
developed by CollabNet (http://www.Collab.Net/).
The following repository access (RA) modules are available:
ra_neon : Module for accessing a repository via WebDAV protocol using Neon.
handles 'http' scheme
handles 'https' scheme
ra_svn : Module for accessing a repository using the svn network protocol.
with Cyrus SASL authentication
handles 'svn' scheme
ra_local : Module for accessing a repository on local disk.
handles 'file' scheme
but when I change the second line code to this:
$handle = popen('svn up --username zmk --password 123456 /home/wwwroot/test/','r');
it doesn't work. output nothing
If I run the 2nd line on the command line,the result is like this,it's OK:
At revision 17.
I know the problem was caused by the permission on linux.
Who has the experience in this field?
give me a demo link,thanks in advance.