JT Practical List
JT Practical List
Practical List
2. Write a Java web application to search a word or phrase on Google search engine. The
application should have following components:
Search.html: It contains a textbox to accept search word or phrase from user.
SearchOnGoogleServlet.java: It should redirect the search query to Google search
engine.
3. Write a Java web application to demonstrate usage of JSP Scripting Elements (Scriptlet,
Expression, Delaration) and JSP implicit objects (out, request, response.)
Use method post to submit a feedback form (html) (Full Name, Email, Subject,
Message)to a jsp page and let jsp page preview the same as confirmation page with
additional text “Feedback received. Thank you.”.
5 Working with Servlets and JSP 2
1. Write a web based Java application which allows the user to download a file from the list of
available files. The application has two components as follow:
FileList.html: It displays a list of files to the user to choose a file to download.
FileDownloadServlet: It takes the user‟s choice for a file to be downloaded and sends
that file in response to the user.
2. Given a design goal below, write a web based application using the following standard
actions: jsp:useBean (with attributes:„id‟, „scope‟, „type‟, and „class‟), jsp:getProperty to
display final results.
Components identified as follow.: Movie.java, Genre.html, ControllerServlet and
DisplayMovieList.jsp
Movie.java provides a bean/class data members, accessors, mutators, toString, default
and parameterized constructor as required.
Genre.html provides a list of movie genres to the user to choose from. Send the chosen
genre as request parameter to ControllerServlet.
ControllerServlet contains a list of movies according to genre. Set a request scope
attribute “mymovies” with the array of movies of the chosen genre. Forward the request
to DisplayMovieList.jsp
DisplayMovieList.jsp displays the names of movies by getting them from the attribute
“mymovies”.
6 Working with JSP and Listeners 2
1. Write a web based java application containing a JSP which performs the simple arithmetic
calculation for given arguments and operator. Write your JSP code using jsp:useBean
action tag.
2. Write a web based Java application which registers and displays the number of hits made by
clients since that application has been started by container. [Use ServletContextListener] .
3. Write a web based Java application which logs the request creation and its destruction.