• Traditionally, there are 2 ways to generate dynamic output (typically HTML or XML) in Java web
applications:
– Servlets
• Java classes with some special methods
(doGet(), doPost(),
Example: out.println(""
+myString + "");
• no separation
between code and presentation!
– JSP (Java Server Pages)
• HTML (or
other) code with embedded Java code (Scriptlets)
• compiled to
Servlets when used for the first time
Example:<%out.println(myString); %>;
• Better, but
still no separation between code and presentation!
Previous Next
0 comments:
Post a Comment