Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Configuring multiple Web apps

 
Steve Brailsford
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please explain how i would configure more than one web application bearing in mind I would need two web.xml files. An example directory structure would help.
Thanks in advance
 
Faraz Masood
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i assume that you are using tomcat
let say your webapplication is in the directory d:\mywebapp
now you should keep all your html files in the same directory
place your web.xml in the d:\mywebapp\WEB-INF
and your class files in the d:\mywebapp\WEB-INF\classes
now in the tomcat directory you will find a file by the name of server.xml <<in %tomcathome%\conf>> open this file and find for a tag <ContextManager>
and add a new context tag
<Context path="/mywebapp>
docBase="C:\mywebapp
</Context>
now you can access your html files by using the url
http://127.0.0.1:8080/mywebapp/.....
but make sure that you start the server first
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic