We can write any Java Logics in our JSP. Then why we are
using servlets(Controller Layer) to interact with the DAO ?

Answer Posted / ami singh

yes you are right but why we write all the business logic in
jsp ,becuse we just in a first step to follow the mvc
architectuer like in struts so thats why we don't want to
write java code in jsp
we just use jsp for a view and he servlet for the
controller for business logic
oherwise you wan o right all business in jsp so is up to you
noone sop you do this
thanks amit singh
amitsing2008@gmail.com

Is This Answer Correct ?    4 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the concept of hashtables?

607


Is empty .java file name a valid source file name?

579


Tell me how many ways are there to initialise an integer with a constant.

635


Can abstract class have private constructor?

492


What is data type modifier?

521






What is a control variable example?

524


Can we override private method in java?

611


How to declare an arraylist in java?

476


Can static methods access instance variables in java?

565


What are synchronized blocks in java?

595


Why is string buffer better than string ?

587


Explain the difference between static and dynamic binding in java?

534


How to check if linked list contains loop in java?

445


What java ide should I use?

554


Which is better arraylist or vector?

564