feri_soft Posted August 29, 2006 Share Posted August 29, 2006 How to create a tumbnail fron blob data and then add a link with the tumnail to te original images.For adding data and viewing it i would use this tutorial:http://php-mysql-tutorial.com/php-mysql-upload.php Quote Link to comment Share on other sites More sharing options...
Iceman512 Posted August 29, 2006 Share Posted August 29, 2006 Hi Feri_soft,It would be very confusing to put all the code in here, so take a look at:http://www.sum-it.nl/en200319.php3Hope it helps you!Regards,Iceman Quote Link to comment Share on other sites More sharing options...
Iceman512 Posted August 29, 2006 Share Posted August 29, 2006 Here's the snippet to link back to the original image; [code]<?php header("Content-type: image/jpeg"); // act as a jpg file to browser $oDatabase = mysql_connect("localhost", "your_database_user_id", "your_database_password"); mysql_select_db("your_database_name", $oDatabase); $sQuery = "SELECT thumbnail FROM your_table WHERE id = $id"; $oResult = mysql_query($sQuery, $oDatabase); $oRow = mysql_fetch_array($oResult); $sJpg = $oRow["thumbnail"]; // To link back to the original image, do the following: echo "<a href='"; echo $Jpg; // Or whatever the image is called in the db echo "'>"; echo $sJpg; echo "</a>"; ?>[/code]It may need some modifications, Regards,Iceman Quote Link to comment Share on other sites More sharing options...
feri_soft Posted August 29, 2006 Author Share Posted August 29, 2006 thanks for reply,i will take a look now Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.