how to nsert and retrieve image into mysql database?

First of all, you won't be inserting an actual image into mysql. You will upload the image into a folder on your server, then MySQL will provide a link or path to that location, so the image can be displayed.

You'll need a column in your database called 'image' and set it to use a 'BLOB' data type. These tutorials should help you get started!

http://www.devarticles.com/c/a/MySQL/Blobbing-Data-With-PHP-and-MySQL/
http://www.anyexample.com/programming/php/php_mysql_example__image_gallery_(blob_storage).xml

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.