PROJECT 3: SERVLET BASICS |
If you haven't done it already, you need to learn how to create, compile, debug and run Java Servlets on the web server by going through our tutorial. In this third project, you need to design a servlet that returns the three pages from the last assignment. Instead of composing three different HTML pages to show different categories of movies available in your store, your servlet will show the movie tables. The site structure of the pages are as follows: ![]() This configuration has only one static HTML page and one servlet. In this configuration, when the user first enters the store by following the “Enter” link, the first HTML page will be generated. Then, when the user clicks on the “Next” button, the browser should send a request to the corresponding servlet in the web server, and the web server will respond with a HTML document containing the next five movies. The most interesting part is when the user click 'Previous' button in the servlet generated page, it should also send a request to the same servlet. However, this time, the servlet will 'know' which five movies the user is requesting, and respond with the previous five movies. Do not implement this part using cookies or sessions, as these are the topics of our subsequent projects. Documentation of the code is important in this and future servlet projects. |
|