Date: 04/20/05 (PHP Community) Keywords: php, mysql, browser, html, database, sql Hi all, $pic_id = get_pic_id($_SERVER['REQUEST_URI']); $table_name = get_table_name($_SERVER['REQUEST_URI']); $file_data = get_file_data($pic_id, $table_name); header("Content-type: " . $file_data['type']); echo $file_data['binary_data']; The functions get_pic_id() and get_table_name() run a regex on the string and return the correct portions of the string that I then pass to get_file_data() and get the binary data. I used to get the pic_id and the table_name from the $_GET string, but I wanted to force the browser to cache the images so a friend suggested using this. Thing is he wrote his version in Python which I dont know. My question to you all is do you know if this possible and if so where can I get the string from? Source: http://www.livejournal.com/community/php/288307.html
|