houssam_ballout Posted April 4, 2010 Share Posted April 4, 2010 Hello all,I am using this tutorial for uploading images to mysql database, http://www.php-mysql-tutorial.com/wikis/my...l-database.aspxbut I don't want them to download, can I view them?Thanks Link to comment Share on other sites More sharing options...
Synook Posted April 5, 2010 Share Posted April 5, 2010 Yes, just don't send the content-disposition header. Link to comment Share on other sites More sharing options...
houssam_ballout Posted April 6, 2010 Author Share Posted April 6, 2010 But how can I view it?it won't work if I echo the corresponding row.Thanks Link to comment Share on other sites More sharing options...
Synook Posted April 6, 2010 Share Posted April 6, 2010 You go to (e.g.) download.php?id=3, and instead of the image downloading it will appear (because you didn't send the content-disposition header). Link to comment Share on other sites More sharing options...
justsomeguy Posted April 6, 2010 Share Posted April 6, 2010 You still need to send a content-type header to tell the browser that it's image data, if that's the only header you send then the browser will just display the image. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.