SlideShare uma empresa Scribd logo
1 de 36
Trainer = Subhasis Nayak CMC
What is JSP ? ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
What it provides? ,[object Object],[object Object],[object Object],[object Object]
Information about JSP ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
JSP life cycle ,[object Object],[object Object],[object Object],[object Object],[object Object]
Advantages of JSP ,[object Object],[object Object],[object Object],[object Object],[object Object]
JSP Architecture Model ,[object Object],[object Object],[object Object]
JSP model 1 ,[object Object],1.request 4.response 2.Create Java beans 3.Retrieve data Not good for Complex EIS/DB Browser JSP Java Beans Suite able for small application. In big application we put huge logic code to JSP.
JSP model 2 ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Cont’d ……  4.Invoke JSP 6.response 2.Create Java beans 3.Retrieve data 2.Use Java beans 1.request EIS/DB Browser Servlet (Controller) Java Beans (Model) JSP (view) ,[object Object],[object Object]
JSP life Cycle. ,[object Object],[object Object],[object Object]
Cont’d …..
Elements of JSP JSP tag description Syntax directive Specifies translation time instruction to JSP engine <%@Directives%> Declaration It declare & define variables , methods. <%! Some java code %> Scriptlets Tags are used to embed java code in JSp page. Allows to write free-form java code in JSP page <%count++%> Expression Used to print value in the out put html file <%=an expression%> Action Provides request time instructions to the JSp engine. <jsp:actionname/> comment Used for documentation <%--Any text--%>
A simple JSP page <html>  <body> <% out.println(&quot;<h1>Hello World!</h1>&quot;);%>  </body> </html>  Scriptlet
The processing of JSP ,[object Object],[object Object],[object Object]
Cont’d ……  ,[object Object],[object Object],[object Object],[object Object]
Let’s see the translated code of a JSP <html>  <body> <h1>Hello World!</h1> </body> </html> out.write(&quot;<html>&quot;); out.write(&quot;<body>&quot;); out.println(&quot;<h1>Hello World!</h1>&quot;); out.write(&quot;&quot;); out.write(&quot;</body>&quot;); out.write(&quot;</html>&quot;); JSP Servlet Don’t worry about Servlet  file of JSP. JSP, why?
Let’s display Something Output swill same The second one is the short hand code
Program displaying date
variables ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Scriptlets ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Declarations ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Directives ,[object Object],[object Object],[object Object],[object Object]
JSP Comments ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
The  include  directive ,[object Object],[object Object],[object Object],[object Object],[object Object]
Actions ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
JSP in XML ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Action – useBean tag ,[object Object],[object Object],[object Object],[object Object],[object Object]
Session in jsp ,[object Object],[object Object],[object Object],[object Object],[object Object]
Program for math calculation Declarative tag Expression tag
Program to display the string
XML style
Compare XML tag with normal Normal JSP tag XML tag of the JSP tag
Program to write scriptlet tag Scriptlet tag
Lab questions? ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Hands on lab Next session

Mais conteúdo relacionado

Mais procurados

Mais procurados (19)

Web Applications and Deployment
Web Applications and DeploymentWeb Applications and Deployment
Web Applications and Deployment
 
Jsp elements
Jsp elementsJsp elements
Jsp elements
 
Jsp element
Jsp elementJsp element
Jsp element
 
JSP diana y yo
JSP diana y yoJSP diana y yo
JSP diana y yo
 
JSP - Java Server Page
JSP - Java Server PageJSP - Java Server Page
JSP - Java Server Page
 
Jsp
JspJsp
Jsp
 
Jsp 02(jsp directives)2003
Jsp 02(jsp directives)2003Jsp 02(jsp directives)2003
Jsp 02(jsp directives)2003
 
JAVA SERVER PAGES
JAVA SERVER PAGESJAVA SERVER PAGES
JAVA SERVER PAGES
 
Jsp chapter 1
Jsp chapter 1Jsp chapter 1
Jsp chapter 1
 
Adam Peller Interoperable Ajax Tools And Mashups
Adam Peller Interoperable Ajax Tools And MashupsAdam Peller Interoperable Ajax Tools And Mashups
Adam Peller Interoperable Ajax Tools And Mashups
 
Implicit objects advance Java
Implicit objects advance JavaImplicit objects advance Java
Implicit objects advance Java
 
Jsp in Servlet by Rj
Jsp in Servlet by RjJsp in Servlet by Rj
Jsp in Servlet by Rj
 
Servlet/JSP course chapter 2: Introduction to JavaServer Pages (JSP)
Servlet/JSP course chapter 2: Introduction to JavaServer Pages (JSP)Servlet/JSP course chapter 2: Introduction to JavaServer Pages (JSP)
Servlet/JSP course chapter 2: Introduction to JavaServer Pages (JSP)
 
Java Server Pages(jsp)
Java Server Pages(jsp)Java Server Pages(jsp)
Java Server Pages(jsp)
 
Java Server Pages
Java Server PagesJava Server Pages
Java Server Pages
 
Unit 4 web technology uptu
Unit 4 web technology uptuUnit 4 web technology uptu
Unit 4 web technology uptu
 
Java Server Pages
Java Server PagesJava Server Pages
Java Server Pages
 
Introduction to the Servlet / JSP course
Introduction to the Servlet / JSP course Introduction to the Servlet / JSP course
Introduction to the Servlet / JSP course
 
Jsp
JspJsp
Jsp
 

Destaque

Destaque (6)

Php, mysq lpart3
Php, mysq lpart3Php, mysq lpart3
Php, mysq lpart3
 
how to create object
how to create objecthow to create object
how to create object
 
Servlet & jsp
Servlet  &  jspServlet  &  jsp
Servlet & jsp
 
Introduction to network
Introduction to networkIntroduction to network
Introduction to network
 
J2ee connector architecture
J2ee connector architectureJ2ee connector architecture
J2ee connector architecture
 
Php, mysq lpart5(mysql)
Php, mysq lpart5(mysql)Php, mysq lpart5(mysql)
Php, mysq lpart5(mysql)
 

Semelhante a Jsp 01

Semelhante a Jsp 01 (20)

Jsp
JspJsp
Jsp
 
Jsp Slides
Jsp SlidesJsp Slides
Jsp Slides
 
JSP
JSPJSP
JSP
 
JSP.pptx
JSP.pptxJSP.pptx
JSP.pptx
 
JSP- JAVA SERVER PAGES
JSP- JAVA SERVER PAGESJSP- JAVA SERVER PAGES
JSP- JAVA SERVER PAGES
 
Learning jsp
Learning jspLearning jsp
Learning jsp
 
Jsp Presentation +Mufix "3"
Jsp Presentation +Mufix "3"Jsp Presentation +Mufix "3"
Jsp Presentation +Mufix "3"
 
J2EE - JSP-Servlet- Container - Components
J2EE - JSP-Servlet- Container - ComponentsJ2EE - JSP-Servlet- Container - Components
J2EE - JSP-Servlet- Container - Components
 
Jsp
JspJsp
Jsp
 
Unit 4 1 web technology uptu
Unit 4 1 web technology uptuUnit 4 1 web technology uptu
Unit 4 1 web technology uptu
 
Jsp
JspJsp
Jsp
 
Comparative Display Technologies
Comparative Display TechnologiesComparative Display Technologies
Comparative Display Technologies
 
Jsp1
Jsp1Jsp1
Jsp1
 
I Feel Pretty
I Feel PrettyI Feel Pretty
I Feel Pretty
 
Boston Computing Review - Java Server Pages
Boston Computing Review - Java Server PagesBoston Computing Review - Java Server Pages
Boston Computing Review - Java Server Pages
 
JSP AND XML USING JAVA WITH GET AND POST METHODS
JSP AND XML USING JAVA WITH GET AND POST METHODSJSP AND XML USING JAVA WITH GET AND POST METHODS
JSP AND XML USING JAVA WITH GET AND POST METHODS
 
Jsp tutorial
Jsp tutorialJsp tutorial
Jsp tutorial
 
Java Server Pages
Java Server PagesJava Server Pages
Java Server Pages
 
The java server pages
The java server pagesThe java server pages
The java server pages
 
Introduction to JSP.pptx
Introduction to JSP.pptxIntroduction to JSP.pptx
Introduction to JSP.pptx
 

Mais de Subhasis Nayak

working with database using mysql
working with database using mysql working with database using mysql
working with database using mysql Subhasis Nayak
 
Php, mysq lpart4(processing html form)
Php, mysq lpart4(processing html form)Php, mysq lpart4(processing html form)
Php, mysq lpart4(processing html form)Subhasis Nayak
 
Oops And C++ Fundamentals
Oops And C++ FundamentalsOops And C++ Fundamentals
Oops And C++ FundamentalsSubhasis Nayak
 
Text mode Linux Installation Part 01
Text mode Linux Installation Part 01Text mode Linux Installation Part 01
Text mode Linux Installation Part 01Subhasis Nayak
 

Mais de Subhasis Nayak (12)

working with database using mysql
working with database using mysql working with database using mysql
working with database using mysql
 
Php, mysq lpart4(processing html form)
Php, mysq lpart4(processing html form)Php, mysq lpart4(processing html form)
Php, mysq lpart4(processing html form)
 
Php, mysq lpart1
Php, mysq lpart1Php, mysq lpart1
Php, mysq lpart1
 
Php, mysqlpart2
Php, mysqlpart2Php, mysqlpart2
Php, mysqlpart2
 
Pointer in c++ part3
Pointer in c++ part3Pointer in c++ part3
Pointer in c++ part3
 
Pointer in c++ part2
Pointer in c++ part2Pointer in c++ part2
Pointer in c++ part2
 
Pointer in c++ part1
Pointer in c++ part1Pointer in c++ part1
Pointer in c++ part1
 
C++ arrays part2
C++ arrays part2C++ arrays part2
C++ arrays part2
 
C++ arrays part1
C++ arrays part1C++ arrays part1
C++ arrays part1
 
Flow control in c++
Flow control in c++Flow control in c++
Flow control in c++
 
Oops And C++ Fundamentals
Oops And C++ FundamentalsOops And C++ Fundamentals
Oops And C++ Fundamentals
 
Text mode Linux Installation Part 01
Text mode Linux Installation Part 01Text mode Linux Installation Part 01
Text mode Linux Installation Part 01
 

Último

Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseAnaAcapella
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...Nguyen Thanh Tu Collection
 
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...ZurliaSoop
 
How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17Celine George
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin ClassesCeline George
 
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfUGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfNirmal Dwivedi
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701bronxfugly43
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfAdmir Softic
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024Elizabeth Walsh
 
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptxHMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptxEsquimalt MFRC
 
Application orientated numerical on hev.ppt
Application orientated numerical on hev.pptApplication orientated numerical on hev.ppt
Application orientated numerical on hev.pptRamjanShidvankar
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxRamakrishna Reddy Bijjam
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxVishalSingh1417
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.MaryamAhmad92
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxJisc
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxAmanpreet Kaur
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibitjbellavia9
 
Salient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsSalient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsKarakKing
 
This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.christianmathematics
 

Último (20)

Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
 
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
 
How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
 
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfUGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024
 
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptxHMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
 
Application orientated numerical on hev.ppt
Application orientated numerical on hev.pptApplication orientated numerical on hev.ppt
Application orientated numerical on hev.ppt
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptx
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
Salient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsSalient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functions
 
This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.
 

Jsp 01

  • 1. Trainer = Subhasis Nayak CMC
  • 2.
  • 3.
  • 4.
  • 5.
  • 6.
  • 7.
  • 8.
  • 9.
  • 10.
  • 11.
  • 13. Elements of JSP JSP tag description Syntax directive Specifies translation time instruction to JSP engine <%@Directives%> Declaration It declare & define variables , methods. <%! Some java code %> Scriptlets Tags are used to embed java code in JSp page. Allows to write free-form java code in JSP page <%count++%> Expression Used to print value in the out put html file <%=an expression%> Action Provides request time instructions to the JSp engine. <jsp:actionname/> comment Used for documentation <%--Any text--%>
  • 14. A simple JSP page <html> <body> <% out.println(&quot;<h1>Hello World!</h1>&quot;);%> </body> </html> Scriptlet
  • 15.
  • 16.
  • 17. Let’s see the translated code of a JSP <html> <body> <h1>Hello World!</h1> </body> </html> out.write(&quot;<html>&quot;); out.write(&quot;<body>&quot;); out.println(&quot;<h1>Hello World!</h1>&quot;); out.write(&quot;&quot;); out.write(&quot;</body>&quot;); out.write(&quot;</html>&quot;); JSP Servlet Don’t worry about Servlet file of JSP. JSP, why?
  • 18. Let’s display Something Output swill same The second one is the short hand code
  • 20.
  • 21.
  • 22.
  • 23.
  • 24.
  • 25.
  • 26.
  • 27.
  • 28.
  • 29.
  • 30. Program for math calculation Declarative tag Expression tag
  • 31. Program to display the string
  • 33. Compare XML tag with normal Normal JSP tag XML tag of the JSP tag
  • 34. Program to write scriptlet tag Scriptlet tag
  • 35.
  • 36. Hands on lab Next session