Hello,
I have a unix command written in a file and I need PHP to read it and execute it. The reason it needs to be read from a file is because the commands symbols mess up the script when put them directly in it. So far I have this:
<?php
$command = readfile("http://localhost/command.txt");
echo shell_exec($command);
?>
Upon running this all I get is the value of the text file and the command is not executing. Is there a way this can be done?
Thanks for any help