title: Warning: fopen(): Filename cannot be empty in php
body: <p>i have a site through which user get video through passing url in field and have save video or download or embed in his play list</p>
  
  <p>i am trying to download video through url and facing this problem</p>
  
  <pre><code>file_put_contents("video/".str_replace(" ","-",$name_vid.".mp4"), fopen($download_url, 'r'));
  </code></pre>
  
  <blockquote>
    <p>Warning: fopen(): Filename cannot be empty in D:\xampp\htdocs\Website\user_get_url_video_check.php on line 382</p>
  </blockquote>