aspose file tools*
The moose likes Servlets and the fly likes how to use css and js file in servlet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Reply locked New topic
Author

how to use css and js file in servlet

rakhi sinha
Ranch Hand

Joined: Mar 26, 2012
Posts: 147
I have problem in using calendar in my servlet ..i dont understand where to save css ,js file and .png image file so that i can use these in my servlet to call the calendar in the servlet .how to give url in the servlet.

Neeraj Dhiman
Ranch Hand

Joined: Dec 19, 2011
Posts: 63

you can store your css, js and image any where in webcontent folder in any hierarchy except WEB-INF Folder. and corresponding path use to access.


Correct Me if i am wrong
Nam Ha Minh
Ranch Hand

Joined: Oct 31, 2011
Posts: 498

Putting HTML code inside servlet may work for the first time, but it will make maintain the code harder.
Why don't you dispatch to a JSP page from the servlet?


PM Me If You Want to get Urgent Help on Java Programming
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61413
    
  67

Please do not cross-post the same question in multiple forums. It wastes people's time when multiple redundant conversations take place. Please click this link ⇒ CarefullyChooseOneForum ⇐ for more information.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to use css and js file in servlet