php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #63444 download ling probem
Submitted: 2012-11-05 22:24 UTC Modified: 2012-11-05 23:00 UTC
From: engineer dot mahmoud22 at yahoo dot vom Assigned:
Status: Not a bug Package: Performance problem
PHP Version: 5.4.8 OS: windows 7
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
43 - 24 = ?
Subscribe to this entry?

 
 [2012-11-05 22:24 UTC] engineer dot mahmoud22 at yahoo dot vom
Description:
------------
when i download file , the file is corrupt becouse it download only 65 kbyte from the file although the size of the file is 10 mega 
and the files type i download is documents word and pdf file



Test script:
---------------
<?php 
session_start();
if(isset($_GET['pro_Id_down'])){
}
require("index.php");
$pro_Id_down = $_GET['pro_Id_down'];
$sqldown = "select * from proposal where P_Id= '$pro_Id_down'";
$query = mysql_query($sqldown);
$result = mysql_fetch_assoc($query);
$type = $result['type'];
$file = $result['File'];
$size = $result['size'];
$name = $result['filename'];

header("Content-type: $type");
header("Content-type: $type");
header("Content-length: $size");
header("Content-Disposition: filename = $name ");
header("Cache-control: private");
header('Content-Transfer-Encoding: binary');
   
 echo $file;
?>

Expected result:
----------------
when downloading the file the file download stoped at 65 kbyte and file corrupt 

Actual result:
--------------
what can i do please ??

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-11-05 23:00 UTC] johannes@php.net
-Status: Open +Status: Not a bug
 [2012-11-05 23:00 UTC] johannes@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 11:01:29 2024 UTC