Possible Duplicate:
Getting around Chrome's Malicious File Warning
Code:
/*
.... Code to authenticate to my mysql and verify that we are an legal user.
*/
$type = mysql_result($AllResult, 0, 'file_type');
$size = mysql_result($AllResult, 0, 'file_size');
$name = mysql_result($AllResult, 0, 'file_name');
$data = mysql_result($AllResult, 0, 'file_content');
session_write_close();
ob_clean();
mysql_close();
header("Content-Transfer-Encoding: binary");
header("Content-type: $type");
header("Content-length: $size");
header("Content-Disposition: attachment;filename=$name");
header("Content-Description: PHP Generated Data");
echo "$data";
I have made a PHP code for downloading files from an longblob in my database and saving it to the users computer. This code is working perfectly on Opera and Firefox. However, on IE and google chrome - If the program is not having an Microsoft SmartScreen license - It will promt the dialog '...name... is not commonly downloaded and can harm your computer'
Illustration:
However; I was wondering whether I could change the header, or If it is possible to get the dialog 'This file can harm your computer. Do you want to keep ..... anyways?' [KEEP] [DISCARD]
An illustration of what the dialog I am talking about:
Update: I Have tried to use both inline and attachment for my Content-Disposition with same result