cucuru Posted January 15, 2010 Share Posted January 15, 2010 hello, I'm using ssh2 extension, the comands execute perfect, but I can't read the response, the returned value of ssh2_exec is always empty: if(!($stream = ssh2_exec($con, "ls -al" )) ){ echo "fail: unable to execute command\n"; } else{ // collect returning data from command stream_set_blocking( $stream, true ); if (!fread($stream,4096)){ echo "empty"; } else { echo "something"; } fclose($stream); } where is my problem? I cant find it! Thank you. Regards Link to comment https://forums.phpfreaks.com/topic/188559-empty-stream/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.