Search and display records from a database.

cs41ao

New member
Local time
Today, 16:28
Joined
Nov 6, 2007
Messages
2
Hello,

I need some assistance. a. First create a JSP page with all the necessary HTML and JSP elements, and call it index.jsp.

Write the appropriate JSP code to connect to the database (using the dbConnector JavaBean) and retrieve the top 5 rated products stored in the database. Display the most relevant information for each record (i.e. product title, price, and rating). The list should look something like:

E.g.:
Product Price Rating
Product Title 1 299 
Product Title 2 £199 
Product Title 3 149 
... ... ...

Each product displayed on the page should have a hyperlink associated with it that takes the user to a page called product.jsp that displays details about that particular product.
index.jsp in such way to include a searching text field somewhere on your pages, in order to search the database for particular products (if you want, you could even include this searching box in every page of your website).

Make the searching mechanism look into the title and description fields of the products table. The results should be displayed in a new page called search.jsp (i.e. you need to create this page).

The results should be displayed in a tabular format (showing product title, price, and rating), and each record should have a link to product.jsp in order to see more details of the particular product.

Thanks
Andy
 

Users who are viewing this thread

Back
Top Bottom