wood burning stoves 2.0
The moose likes Servlets and the fly likes JSP & Servlet Differences Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "JSP & Servlet Differences" Watch "JSP & Servlet Differences" New topic

JSP & Servlet Differences

pulijala hari
Ranch Hand

Joined: May 14, 2005
Posts: 70
Hi all,

I would like to know What can be done with Servlets that can not be done by JSP? and vice versa?

Could you please let me know this as this was asked in an interview for me?

David O'Meara

Joined: Mar 06, 2001
Posts: 13459

This has been discussed recently.
[ October 10, 2005: Message edited by: David O'Meara ]
ankur rathi
Ranch Hand

Joined: Oct 11, 2004
Posts: 3830
Whatever you can do with JSP, Servlet can do that because ultimately JSP is converted into Servlet before execution and after compilation.

I am not sure whether JSP can do all servlet works.
David O'Meara

Joined: Mar 06, 2001
Posts: 13459

Not quite, a JSP also has access to things like Tag libraries and JSTL which are not available in Servlets. Some of these features can be accomplished in other ways in Servlets, but not all.
I agree. Here's the link: http://aspose.com/file-tools
subject: JSP & Servlet Differences
It's not a secret anymore!