First of all, in servlet u write html code inside java and in jsp u write ur java inside html. thus the presentation layer is seperated. Thus if u want to write lot of html things that has to come to browser again , then stick with JSP. only if u want something to work in the background go for servlet. sakthi
Originally posted by vinod: When should i go for servlets and when should i go for JSP. I would be grateful if anyone of u could explain this.Plz give me with examples.
Joined: Nov 22, 2008
I think JSP can d0 everything and even something more what servlets can do---then what is the need of servlets???