Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Use JSTL in the Cart application Download, unzip and open the ch09_ex2_cart proj

ID: 3597636 • Letter: U

Question

Use JSTL in the Cart application

Download, unzip and open the ch09_ex2_cart project. https://drive.google.com/file/d/0B5HjVVkWJYBIMWlFTTAwMzlFRjA/view?usp=sharing

Open the web.xml file. Note that the ProductServlet class is mapped to the /loadProducts URL and that this URL is set as the only welcome page. As a result, when this app starts, the browser issues an HTTP GET request for the ProductServlet class.

Open the ProductServlet.java file. Note how this servlet uses the doGet method to read an ArraryList of Product objects from the projects.txt file and store them as an attribute of the session object.

Make sure the JSTL library is available on this application.

Test the application to make sure it works correctly.

Open the index.jsp file and add the taglib directive that imports the core JSTL library. Then, add a forEach tag that loops through the ArrayList of Product objects and displays one row for each product. To do that, you can use EL to display the properties of each Product object. ) Be sure to delete any old code that you no longer need.)

Test the application to make sure that it works correctly.

To prevent against XSS attacks, add the out tag to any EL values that should be escaped before they are returned to the browser.

Test the application to make sure that it still works correctly.

Download Files: https://drive.google.com/file/d/0B5HjVVkWJYBIMWlFTTAwMzlFRjA/view?usp=sharing

Explanation / Answer

Please find working project in below location. I tested it in Netbeans 8.0 ersion.

Location: https://drive.google.com/drive/my-drive

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote