I am trying to create and append to a text file using PHP SSH2. The command I am sending is this:
$cmd = "cd $output_directory; cat > myfile.txt; echo \"My Text\" >> myfile.txt";
The file is created, but the text is not appended to it.
Appreciate any input as to where I am going wrong.