I'm new on this forum so first I would like to greet you all.
I'm bulding struts2 + hibernate +
tomcat application and now I have a problem.
Users should be able to upload their photos and later that photos should be visible on their profile page.
Uploading a file in struts2 is , as we all now, super easy so I find myself with a File object in my Action class.
What should I do next? My first idea was to store a file on images folder in my web app root so I can easily reference it from html later but I can't find path for that. Second idea is to put it in database as blob or something but how to display it later?
Any ideas, examples? It's a bit surprising for me that googling didn't provide any answers because it seems like a common scenario...