• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Diff Between Servlet and JSP

 
Ranch Hand
Posts: 211
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,
What is the main diffrenece between JSP and Servlet......which is faster (Servlet or JSP and why???).When to use servlet and when to use JSP...Please Expalin.
 
Ranch Hand
Posts: 76
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
jsp's are nothing, but servlets in the background. A JSP page is compiled into servlet with the first request. jsp's advantage is that with the use of JSP it's easy to seperate presentation with business layer. Designer can maintain the JSP pages, the logic for extracting data for presentation and display can be written in Beans/taglibs. Servlets on the other hand tend to mix presentation with business.so at presentation layer (where a lot of html/wml is involved), you would like to use JSP and if you want to use it as controller(or for anything that involves little or no HTML), you would use servlets.
hth
 
You got style baby! More than this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic