title: How to get video size of compressed video by ffmpeg?
body: <p>Hi we are using ffmpeg for compressing the video through php script, now what i need is i want to get the video size of compressed image, but am getting an video path so kindly guide me how i need to over come this?</p>
  
  <p>Below is the code what i used for compressing the video</p>
  
  <p>original path</p>
  
  <pre><code>$path = "sample.mp4";
  </code></pre>
  
  <p>Command to compress</p>
  
  <pre><code>exec("ffmpeg -i sample.mp4 -vcodec h264 -acodec aac -strict -2 compressed_video.mp4);
  </code></pre>
  
  <p>The command what i used for getting video size</p>
  
  <pre><code>$compressed_video_information = exec("ls -h1 compressed_video.mp4);
  echo $compressed_video_information;
  </code></pre>
  
  <p>I get just file path instaed of getting video file size, so someone help me how to overcome this issue?</p>