Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7620813
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T04:02:06+00:00 2026-05-31T04:02:06+00:00

In Eclipse, the folder structure when I create a Dynamic Web Project is [srikanth@hana

  • 0

In Eclipse, the folder structure when I create a Dynamic Web Project is

[srikanth@hana Sample]$ ls -R
.:
build  src  WebContent

./build:
classes

./build/classes:

./src:

./WebContent:
index.html  META-INF  scripts  WEB-INF

./WebContent/META-INF:
MANIFEST.MF

./WebContent/scripts:
jquery-1.7.1.js

./WebContent/WEB-INF:
lib  web.xml

./WebContent/WEB-INF/lib:

As you can see, there is this WebContent directory, When I copy the directory structure from Eclipse workspace and put in webapps directory of Tomcat, it didn’t work. But, if I moved all the directories and files under WebContent directory a level above, it worked fine.

This is the folder structure in Tomcat’s webapps directory under application:

[srikanth@hana Sample]$ ls -R 
.:
build  index.html  META-INF  scripts  src  WEB-INF

./build:
classes

./build/classes:

./META-INF:
MANIFEST.MF

./scripts:
jquery-1.7.1.js

./src:

./WEB-INF:
lib  web.xml

./WEB-INF/lib:

So, now I can just go to http://localhost:8080/Sample and can go to index.html properly

What am I doing wrong? Why didn’t it work just copying the application
from Eclipse to tomcat webapps directory directly? Why do I have to
change the directory structure?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T04:02:08+00:00Added an answer on May 31, 2026 at 4:02 am

    When I copy the directory structure from Eclipse workspace and put in
    webapps directory of Tomcat, it didn’t work. But, if I moved all the
    directories and files under WebContent directory a level above, it
    worked fine

    Not sure what you mean if I moved all the directories and files under WebContent directory a level above, it worked fine here and what you mean by saying a level above.

    What you should be doing is not copy anything manually but right-click on the project and select Export as WAR option.
    This will create a file named Project.war that contains the proper file structure i.e. WEB-INF etc that you are supposed to put under tomcat’s webapps dir

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following directory structure of a project: Folder project in Eclipse: --folder
I am creating a project with eclipse, but am unfamiliar with their folder structure.
Is it possible in Eclipse to create a separate Folder in a package? When
I'd like to create a folder under a package in Eclipse... The purpose of
I created a maven2 project in eclipse, and then I moved the folder to
I a folder structure like so: src\java\com\company\resources\xmlFile.xml The xml file is in the package
Possible Duplicate: Auto refresh eclipse project upon folder update I have been working with
I have a Java project which has this file structure (shown in Eclipse): ProjectName
Every now and then I have a problem with SVN inside eclipse folder gets
Currently my eclipse source folder display the entire package path and java files under

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.