Hi, my cuestion is:
I'm trying create a file from a managed bean of my jsf 2.0 aplication. the problem is that i want to create the file in the root of my web aplication or in any othe folder under the root, but the file is created somewhere else in the server.
i'm using glassfish v3.
when i use netbeans to deploy and run the aplication the file is created in domains/mydomain
and when i deploy it manualy the file is created in domains/mydomain/config
this is the code of a bean made for testig that:
@ManagedBean
@RequestScoped
public class Mybean {
/** Creates a new instance of Manejo */
public Manejo() {
}
public String createmyfile(){
File f = new File("testfile.txt");
try{
f.createNewFile();
}catch(IOException e){
e.printStackTrace();
}
return "index";
}
}
[Message sent by forum member 'samanosuke31']
http://forums.java.net/jive/thread.jspa?messageID=480344