What is the difference between JSP and Servlet?
Answer Posted / abhimanyu
Both servlet and jsp are web components. But servlet is
best suited for request processing, handling the business
logic while jsp is suitable for content generating .Its
easy to include html tag in jsp rather than servlet.Also
jsp is compiled to servlet when first loaded to
webserver.So in many framework servlet act as a controller
while jsp as a view.Also implicit object and action
elements available in jsp but not in servlet.jsp seprates
busigness Logic.
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
How to include static files in a JSP page?
What are the different types of jsp directive?
Explain some jsp life-cycle methods that can be overridden.
Can you use javascript in jsp?
How to configure init parameters for jsp?
Can jsp contain javascript?
What are the possible values for language directive?
Can a jsp page process html form data?
Why is used in jsp?
What is a scriptlet?
What is directive jsp?
What is server context?
What are scriptlets in jsp?
What is scripting elements in jsp?
Why do we use expression language in jsp?