Meaningless Drivel is fun!
The moose likes Servlets and the fly likes JSP, Servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "JSP, Servlets" Watch "JSP, Servlets" New topic

JSP, Servlets

sameer ranadive

Joined: Oct 07, 2003
Posts: 5
What r the advantages of servlet over jsp?

thanks & regards<br />sam
Pradeep bhatt
Ranch Hand

Joined: Feb 27, 2002
Posts: 8927

Please post in the Servlets forum.

Sainudheen Mydeen
Ranch Hand

Joined: Aug 18, 2003
Posts: 218
During the 'Page translation phase' of JSP life-cycle, JSPs are parsed and a java file containing the corresponding servlet is created. If you have more diplay logic go with JSP.
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15302

Moving to the Servlets Forum.

GenRocket - Experts at Building Test Data
Ramakrishnan thiyagarajan
Ranch Hand

Joined: Oct 07, 2003
Posts: 57
the main difference is jsp s are precompiled servlet and
jsps are not pure java code.
Tim Baker
Ranch Hand

Joined: Oct 04, 2003
Posts: 541
yes JSPs are HTML mixed with the Java code, Servlets are a java program that outputs HTML code. if most of the HTML is generated by the program and not fixed use servlets. if most of the HTML is static with small dynamic portions use JSP either with or without beans. For in between stuff use JSP with beans or servlets.

Kim Jong II (North Korea's Dear Leader) said:Nuclear weapons don't kill people, people kill people.
I agree. Here's the link:
subject: JSP, Servlets
It's not a secret anymore!