Saturday, 14 September 2013

shell_exec probably not working

shell_exec probably not working

i understand this might be a little silly to ask but i can't seem to get
shell_exec to work in my php code.
In the code bellow $cmdstring holds the command string but it is not being
executed for some reason. I tried to echo it and copy paste it in the
commandline and that worked fine. So it seems like it has something to do
with shell_exec.
I tried searching the net but I couldn't find any suitable answer.
move_uploaded_file($_FILES["file"]["tmp_name"],"C:xampp\htdocs\docman\docs\\"
. $_FILES["file"]["name"]);
$cmdstring='C:\xampp\htdocs\docman\docs\pdftotext
'.$_FILES['file']['name'].' '.$modifedfilename.'.txt';
shell_exec($cmdstring);
mysql_query($thequery) or die("DAMN");
echo "Upload Successful";

No comments:

Post a Comment