Multiple choice technology programming languages

Which element of the deployment descriptor of a web application includes the welcome-file-list element as a subelement. Select the one correct answer.

  1. web-app

  2. welcome-file

  3. servlet

  4. file-list

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The welcome-file-list element is a direct child of the web-app root element in web.xml. It defines the list of files the server should look for when a client requests a directory URL. Option B (welcome-file) is a subelement within welcome-file-list, not its parent. Options C and D (servlet, file-list) are not valid parents for welcome-file-list.

AI explanation

The welcome-file-list element (which lists default files like index.html) is defined as a sub-element of the top-level web-app element in web.xml, since web-app is the root element containing all deployment descriptor configuration. welcome-file is itself a child of welcome-file-list rather than the other way around, and servlet/file-list are unrelated elements.