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...

waht is the main diference b/w servelts and JSP ?

Answer Posted / shakir khan

In terms of creating a Grapical user interface,servlet is
tough to use.Because you have to write huge code to send
html text to client.This is automatically done for you,when
you write a JSP,Using its tags etc.You can check the
generated servlet and try to judge the code you didn't have
to write.

In servlet using OutputStream,we can send byte streamS like
images.or
We can use customized OutputStream and do whatever we can
with it.Whereas with JSP we can output only
characters.Since PrintWriter is character based.

The advantage of JSP is that they are documentric servlets
look and act like programs.

The power of jsp is that they are server based and provides
a framework for web based application.

JSP is a flat file that are translated at runtime in to a
servlet.JSP are useful for presentation oriented task such
as html rendering.

JSP are high level extension of servlet,it enable the
developer to embed java code in html pages.JSP pages are
finally complied in to a servlet.Complied servlet is used
by the engine to serve the request.

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When is the servlet instance created in the life cycle of servlet? What is the importance of configuring a servlet?

1044


Explain get and post.

1095


What are the supporting protocol by HttpServlet ?

1174


Explain servlet events?

992


What are the life-cycle methods for a servlet?

990


How the servlet is loaded?

1067


Is servlet a server side scripting language?

1113


What is api in servlet?

1008


List the Different types of servlet?

1023


What is url encoding and url decoding

1139


Write all the phases defined in servlet life cycle?

1128


What do you mean by default initialization in java servlet?

1081


What exactly is a servlet?

986


What is cookie in servlet?

1043


What do you mean by scope object and what are its types?

1054