What is the difference between Java Servlet & JSP?



What is the difference between Java Servlet & JSP?..

Answer / vengat

Both use server-side Java to dynamically generate web
pages. The source code to a JSP looks like HTML, with Java
embedded inside funny tags (*); the source code to a
servlet looks like Java, with HTML embedded in out.print
(...) statements. Both use the Servlet API to communicate
with the web server and the client. In fact, a JSP gets
compiled into a servlet, so they're almost identical in
terms of expressive power. The choice is, whether you're
more comfortable coding your pages in Java or in JSP-style
HTML


Though the both are identical, they have different roles in
the Model View Controller (MVC) architecture. View
corresponds to JSP, Controller corresponds to Servlet and
Model to BusinessLogic + Database

Is This Answer Correct ?    7 Yes 0 No

Post New Answer

More JSP Interview Questions

How do we configure init params for jsp?

0 Answers  


Explain the various scope values for <jsp:useBean> tag.

0 Answers  


What is session management in jsp?

0 Answers  


What is jsp include tag?

0 Answers  


How does jsp engines instantiate tag handler classes instances?

0 Answers  






What is the use of session management?

0 Answers  


What is jsp life cycle?

0 Answers  


What does .com stand for?

0 Answers  


How to retrieve warnings?

0 Answers  


How do you delete the session data?

0 Answers  


Can a jsp page instantiate a serialized bean?

0 Answers  


Give uses of object cloning?

0 Answers  


Categories