title: Google Drive API httpRequest download file dialog box
body: <p>I'm new to PHP and I've been using Google Drive PHP API.</p>
  
  <p>This is my code:</p>
  
  <pre><code>function downloadFile1($service,$downloadUrl,$client) {
  
      if ($downloadUrl) {
        $request = new Google_Http_Request($downloadUrl, 'GET', null, null);
  
        $SignhttpRequest = $client-&gt;getAuth()-&gt;sign($request);
        $httpRequest = $client-&gt;getIo()-&gt;makeRequest($SignhttpRequest);
  
    if ($httpRequest-&gt;getResponseHttpCode() == 200) {
  
      return $httpRequest-&gt;getResponseBody();
  
    } else {
    // An error occurred.
      return null;
    }
   } else {
    // The file doesn't have any content stored on Drive.
     return null;
   }
  }
  </code></pre>
  
  <p>So far so good. But I want to get a dialog box to save the file to my computer (When I get the return result). How could I get that?</p>
  
  <p>[If I perform a     </p>
  
  <pre><code>$content = $httpRequest-&gt;getResponseBody();
  print_r($content);]
  </code></pre>
  
  <p>I can see the content of the file in the webpage, but I want to download it!]</p>
  
  <p>Thanks in advance!</p>