CGS4854 Homework 1

Due Friday, 2/8 (late 6am, 2/9)

You are to create a service oriented web site. You will be adding features throughout the semester. The type of service that you provide is your choice. For example, the site that was developed in the book kept track of a user's hobby and aversion. Try to be creative in picking your site. There are already enough book sellers on the web and one site that keeps track of hobbies is enough.

Choose a service that interests you. Later in the course, you will be adding additional fields to this site for an integer, a floating point number and a calculation using these numbers. Think of a site that will be able to be expanded in this way.

On each page of the application, add interesting information about your site. Each page must have different information about the site. The information must not be about how to navigate to the next page.

Create a Web Application using NetBeans

Create a new web application in NetBeans, named your-username (replace your-username with your user name).
  1. If there is not a web.xml file in the WEB-INF folder, then select New File -> Web -> Standard Deployment Descriptor (web.xml) from the NetBeans menu.
  2. Use the secure web.xml file.
  3. Restrict access to this web site to you and me (this is controlled by the secure web.xml file)
  4. Edit the tomcat users file so that you can access your app in your local NetBeans.
  5. Add a folder named styles in the root folder (Web Pages folder in NetBeans).
  6. Modify the index.jsp that is in the root of the web app.
    1. Be sure it uses the Doctype and Meta tags for HTML 5.
    2. Add a paragraph of at least four sentences that describes the service that you are providing.
    3. Validate the JSP at http://www.w3c.org.
    4. Use the stylesheet in the page.
    5. Add a relative, hypertext link to the controller, so I can see it easily.
    6. Add a relative, hypertext link to the style sheet, so I can see it easily.

JSP Controller

Implement a JSP controller for your application. The controller should behave like the JSP controller from Chapter 2 of the book.
  • The web app must use the secure web.xml file and should only allow you and me to access your application: Edit tomcat users
  • After the app is running in NetBeans, upload it and run it on ocelot: Uploading a WAR file
  • ROOT Web Application on ocelot

    If you have not received your Tomcat host number, please create your webapps on ocelot and request a host number.

    After you have created the ROOT and manager web apps on ocelot, you will need to create an index.jsp file in the ROOT web app. This will be the welcome page for your host on ocelot. It should have links to the manager web app and the username web app. If you have done the extra credit, then also include a link to the extra credit web app.

    Be sure you have the following links in the ROOT/index.jsp file on ocelot.

    Hand In Assignment

    To hand in the assignment, zip the cgs4854 directory and upload it.

    Be sure that all your files and subdirectories are included in the zip file.
    After uploading, do not modify your files on ocelot until after your assignment has been graded.