This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Hi there, I'm using struts and JBoss to upload and save files on the disk. The application comes our as ear -> war If I'm not wrong the ear file is actually extract and deployed in a temporary folder, right? So, what would be the best way to specify the location where to save the file, I mean inside my webapp.
Thanks in advance [ May 27, 2007: Message edited by: Alessandro Ilardo ]
In a servlet or jsp you can use the getRealPath method convert a path relative to your application root into the OS specific path, this can help you to create a java.io.FileOutputStream or java.io.FileWriter as per your requirement, which could be the destination of your uploaded files within your webapp.