View Single Post
Old 01-02-2009, 05:07 PM   #3 (permalink)
moiseszaragoza
The Wanderer
 
Join Date: Dec 2008
Posts: 10
Thanks: 0
moiseszaragoza is on a distinguished road
Default

first of all i want to say happy new yrs to every one

i finaly was ebel to get ffmpg installed

What i am doing is making sure i can upload to a directory

PHP Code:

<?php 

function uploadtoDirectory(){
        
$uploaddir     =     '_files/';
            
$uploadfile =     $uploaddir basename($_FILES['file']['name']);
            
#$uploadfile =     $uploaddir . $_SESSION['UserID'] . date("YmdHis"). ".flv";  
            
$filename     =    basename($_FILES['file']['name']);
            
#$filename     =     $_SESSION['UserID'] . date("YmdHis"). ".flv";
            
if (move_uploaded_file($_FILES['file']['tmp_name'], $uploadfile)) {
            
#    echo "File is valid, and was successfully uploaded.\n";
            
} else {
            
#    echo "Possible file upload attack!\n";
            
}
            
#echo 'Here is some more debugging info:';
            #print_r($_FILES);
            #echo($uploadfile);
            
YorshffmpegWrapper->YorshffmpegWrapper($filename$ffmpeg_path "ffmpeg");
    }


    
$Submit $_POST['Submit'];
    echo(
$submit);
    if(
$Submit!=NULL){
         
uploadtoDirectory();
    }
?>
<form action="" method="post" enctype="multipart/form-data" name="form1" id="form1">
  <table width="760" border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td>&nbsp;</td>
      <td>&nbsp;</td>
    </tr>
    <tr>
      <td>File Lookup </td>
      <td><input name="file" type="file" size="54" title="browse" /> </td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td><input type="submit" name="Submit" value="Submit" /></td>
    </tr>
  </table>
</form>
but i am missing the part where i interface with FFMPG

i think there might me a problem with this line

YorshffmpegWrapper->YorshffmpegWrapper($filename, $ffmpeg_path = "ffmpeg");
moiseszaragoza is offline  
Reply With Quote