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

Answer Posted / babu

ya u can write your java logic's Jsp or u can use Jsp action
tags to implement the business logic. But if u do like this
your source code may be viewed and used by the others, for
restricting or preventing your source code we are using mvc
architecture like in struts so that's why we don't want to
write java code in Jsp.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is difference between fail-fast and fail-safe?

580


What is a dynamic array java?

505


What is lastindexof in java?

538


what is a green thread? : Java thread

566


What are the differences between getting and load method?

534






What is the purpose of assert keyword used in jdk1.4.x?

553


What is ternary operator in java?

587


Explain the difference between an object-oriented programming language and object-based programming language?

543


What is double in java?

506


Is logger a singleton?

513


Is java pass by value or pass by reference?

532


How do you remove duplicates from an array in java?

524


How to call one constructor from the other constructor ?

595


Is string is a keyword in java?

543


What are the different approaches to implement a function to generate a random number?

562