• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

where to use these things in good programming way

 
ajay atthuluri
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i know java upto servlets and jsp, i am having a problem that in which conditions we have to use jsp and in which condition we have to use servlets, and i have to know where to write the jdbc code in good programming case, can any hep mee.......
 
Ashwin Sridhar
Ranch Hand
Posts: 277
Flex Oracle Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jsps are used for View. It is mainly used for displaying to the client.
Servlets are used for controllers. This contains Business logic.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65124
91
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you are putting Java code in your JSP, you're doing wrong.
If you are creating HTML in a servlet, you're doing it wrong.

Perhaps this article might be helpful.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic