Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what is the difference between Servlet and JSP?Advantage of
JSP over Servelt?Any concept present in JSP which we cant
implement in Servlet?

Answer Posted / fazal

1)A JSP is typically oriented more towards displaying
information, and a servlet is more oriented towards
processing information. For example, a JSP might display a
report, while a servlet would process a user submitted
form. These uses are not exclusive, but they are optimized
more for performing tasks in this manner. It is much easier
to incorporate HTML coding into a JSP than a Servlet. It is
also easier to write more complex Java code in a servlet.

2)JSP has Implicit objects and Servlets do not.
3)JSP and Servlet both define the server end functionality
to provide dynamic outputs ,As we know our HTML is only the
client end technology version which runs on client browser.
JSP and Servlet differ each other in terms of represntation
and execution cycle. Servlet are full functional java codes
that define the output like write to stream files in
protocol defined ways, JSP on the other hand is Role
Sepated format to do so where a ordinary web designer
designes how will be the presentation of the data and
Programmer defines the functinality to provide the
underlying things represented in conditional and non
conditinal ways , But here is the magic of JSp that merges
the both HTML represntation mixed with JAVA scriptlets.

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a generic servlet?

958


Can you use javascript in servlets?

1089


What is cookie? Why is cookie used?

1060


Write a program to show the functionality of servlets.

1014


How can we achieve transport layer security for our web application?

1040


Difference between GET and POST?

1163


How do I know if java is running on linux?

1127


What are the advantages of cookies?

1126


Which method is called when reference variable is passed in system.net?

2409


What is servlet configuration?

1071


What is url encoding and url decoding

1156


Is it possible to have a constructor inside the servlet?

1016


Why is http protocol called as a stateless protocol?

1035


What is servlet and how it works?

978


How to create war file?

1168