2
// This script accepts an ID and looks in the user's session for stored thumbnail data.
3
// It then streams the data to the browser as an image
5
// Work around the Flash Player Cookie Bug
6
if (isset($_POST["PHPSESSID"])) {
7
session_id($_POST["PHPSESSID"]);
12
$image_id = isset($_GET["id"]) ? $_GET["id"] : false;
14
if ($image_id === false) {
15
header("HTTP/1.1 500 Internal Server Error");
20
if (!is_array($_SESSION["file_info"]) || !isset($_SESSION["file_info"][$image_id])) {
21
header("HTTP/1.1 404 Not found");
25
header("Content-type: image/jpeg") ;
26
header("Content-Length: ".strlen($_SESSION["file_info"][$image_id]));
27
echo $_SESSION["file_info"][$image_id];
b'\\ No newline at end of file'