title: PHP Youtube downloader API Download file name videoplayback
body: <p>I am using Youtube download API when i click on download button video is downloading but filename showing "videoplayback.MP4"
  My code:</p>
  
  <pre><code>&lt;?php
  $url="http://hddir.com/ajax/api.php?type=downlink&amp;v=Is3S-6hHQLk";
  $c=curl_init();
  curl_setopt($c,CURLOPT_RETURNTRANSFER,1);
  curl_setopt($c,CURLOPT_URL,$url);
  $contents=curl_exec($c);
  curl_close($c);
  $someObject = json_decode($contents);
  foreach($someObject as $obj){
  $url=$obj-&gt;url;
  $format=$obj-&gt;format;
  echo '&lt;a href="'.$url.'" download&gt;video '.$format.'&lt;/a&gt;&lt;/br&gt;';
  }
  ?&gt;
  </code></pre>
  
  <p>Result  <a href="http://new.hdbuddy.com/test.php" rel="nofollow noreferrer">result of above code</a></p>