How can I setup Tomcat to access external directory
Hi,
I am stuck with the same issue here.
I am using IntelliJ Idea 8, Tomcat 5x.
I have made an external folder C:/uploads/images and C:/uploads/docs where in the uploads images and documents are stored.
When I start Tomcat from the command line i.e. startup.bat, the images can be accessed in the normal way like "http://locahost:8080/images/user1.jpg".
<Context path="/uploads" docBase="C:\uploads\" crossContext="true"/>
is the content of the xml file which I created and saved under C:\Tomcat\conf\Catalina\localhost
But the funny thing is that when I start Tomcat from IntelliJ Idea, it shows up
"HTTP 400 Bad Request"
How do I make this uploads directory accessible from my application.
Please help !
Regards,
broshni
请先登录再写评论。
Hello,
did you try to enable 'Deploy application configured in Tomcat instance' checkbox in Tomcat run configuration?
>
>
>
>
>
>
--
Nikolay Chashnikov
Software Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"