aspose file tools*
The moose likes Tomcat and the fly likes Javascript files in Tomcat Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Javascript files in Tomcat" Watch "Javascript files in Tomcat" New topic
Author

Javascript files in Tomcat

Jason Low
Greenhorn

Joined: Feb 11, 2012
Posts: 7
Hi

I am trying to create a web application using the Spring MVC framework, but I am not sure where Javascript files go within the folder structure. Does it go within the WEB-INF folder or else where??

Thanks!
Jay
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

No, they go anywhere but there. The browser has to be able to download them. So just treat them exactly the same as you would treat an image or an HTML file in your web application.
Jason Low
Greenhorn

Joined: Feb 11, 2012
Posts: 7
I actucally just figured it out a few minutes ago haha. I placed them in a new folder under WebContent. Thanks for the reply though.


Paul Clapham wrote:No, they go anywhere but there. The browser has to be able to download them. So just treat them exactly the same as you would treat an image or an HTML file in your web application.


Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16012
    
  19

I usually put them in a folder named "scripts", just like I put my stylesheets in a folder named "styles".


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Javascript files in Tomcat