getting image from db

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • kaleeswaran
    New Member
    • Mar 2007
    • 132

    getting image from db

    hi!
    i am doing banking project using struts and mysql.i uploaded the client image into the data base.i should retrieve the image from the data base using popup window.how to do that ?,.,,
    thank you,
  • kreagan
    New Member
    • Aug 2007
    • 153

    #2
    Originally posted by kaleeswaran
    i should retrieve the image from the data base using popup window. How to do that?
    I'm sorry, I'm really confused. Are you saying the popup window will actively retrieve the image or are you asking if this is a good idea. Though there are other design techniques, I'm a little familiar with MVC (Model View Controller). The View (popup window) shouldn't know the database exists.

    If I was designing it, the controller would retrieve the information from database when an event has been triggered, pop up a window, then shove the picture into the view.

    As you can see, the act of gathering the picture and displaying the picture are decoupled. I suggest looking at Swing Tutorials on popups and displaying pictures along with tutorials on how to store and retrieve pictures from a database.

    If you can't store a picture in the database, (I don't think you can), you can store the picture's path name in the database.

    Comment

    Working...