An Introduction to JavaServer™ Pages Prepared by Nicole Swan.

Slides:



Advertisements
Similar presentations
Java Server Pages Jeffrey Jongko. Introduction Java Server Pages (JSP) technology was created by Sun Microsystems and is built on top of Sun’s Java Servlet.
Advertisements

JSP1 Java Server Pages (JSP) Introducing JavaServer Pages TM (JSP TM ) JSP scripting elements.
 Copyright Wipro Technologies JSP Ver 1.0 Page 1 Talent Transformation Java Server Pages.
Java Servlet & JSP © copyright 2005 SNU OOPSLA Lab.
DT211/3 Internet Application Development Active Server Pages & IIS Web server.
Server-Side vs. Client-Side Scripting Languages
JSP: JavaServer Pages Juan Cruz Kevin Hessels Ian Moon.
Sapana Mehta (CS-6V81) Overview Of J2EE & JBoss Sapana Mehta.
28/1/2001 Seminar in Databases in the Internet Environment Introduction to J ava S erver P ages technology by Naomi Chen.
Introduction to Web Application Architectures Web Application Architectures 18 th March 2005 Bogdan L. Vrusias
Outline IS400: Development of Business Applications on the Internet Fall 2004 Instructor: Dr. Boris Jukic Server Side Web Technologies: Part 2.
DT228/3 Web Development JSP: Directives and Scripting elements.
Java Server Team 8. Overview What is a Java Server? History Architecture Advantages Disadvantages Current Technologies Conclusion.
Introduction to Servlet & JSP
Comp2513 Java Server Pages Daniel L. Silver, Ph.D.
1 Java Server Pages Can web pages be created specially for each user? What part does Java play?
CMPUT 391 – Database Management Systems Department of Computing Science University of Alberta CMPUT 391 Database Management Systems JavaServer Pages (JSP)
JavaServer Pages TM Introduce by
2440: 141 Web Site Administration Web Server-Side Programming Professor: Enoch E. Damson.
Server-side Technologies
Introduction Servlets and JSP Celsina Bignoli
Java Server Pages (JSP) Presented by: Ananth Prasad & Alex Ivanov May 10, 2001.
Overview of JSP Technology. The need of JSP With servlets, it is easy to – Read form data – Read HTTP request headers – Set HTTP status codes and response.
DAT602 Database Application Development Lecture 15 Java Server Pages Part 1.
Server Side Scripting Norman White. Where do we do processing? Client side – Javascript (embed code in html) – Java applets (send java program to run.
M. Taimoor Khan * Java Server Pages (JSP) is a server-side programming technology that enables the creation of dynamic,
Server- Side technologies Client-side vs. Server-side scripts PHP basic ASP.NET basic ColdFusion.
Architecture Of ASP.NET. What is ASP?  Server-side scripting technology.  Files containing HTML and scripting code.  Access via HTTP requests.  Scripting.
CIS 285 ROBINSON WINTER 2005 CIS 285 Web Application Development with Java CIS 285 Sinclair Community College Instructor: Mary Robinson.
Basics of Web Databases With the advent of Web database technology, Web pages are no longer static, but dynamic with connection to a back-end database.
3/8/00asp00 1 Active Server Pages from Microsoft Nancy McCracken Northeast Parallel Architectures Center at Syracuse.
Modern Software Technologies Java™, J2EE™, JSP™, JDBC™ by Radoslav Tr. Ivanov
Using JavaBeans and Custom Tags in JSP Lesson 3B / Slide 1 of 37 J2EE Web Components Pre-assessment Questions 1.The _____________ attribute of a JSP page.
Java Server Pages Lecture July Java Server Pages Java Server Pages (JSPs) provide a way to separate the generation of dynamic content (java)
Wanna know how to get from “Y” to“K” ? Farisai Mabvudza Uma Rudraraju & George Wells Greg Foster & Presented By…Supervised By…
Stanisław Osiński, 2002JSP – A technology for serving dynamic web content Java Server Pages™ A technology for serving dynamic web content Stanisław Osiński,
Chapter 10 Overview of JSP Technology. Understanding the need for JSP JSP technology enables to mix regular, static HTML with dynamically generated content.
JAVA SERVER PAGES CREATING DYNAMIC WEB PAGES USING JAVA James Faeldon CS 119 Enterprise Systems Programming.
Webcommerce Computer Networks Webcommerce by Linnea Reppa Douglas Martindale Lev Shalevich.
Web Server Programming 3. Server side includes. HTML+ (‘hole’) technologies Uses ‘HTML+”, HTML (or XML) extended with code. Very many different varieties.
CSC 2720 Building Web Applications JavaServer Pages (JSP) The Basics.
1 MSCS 237 Overview of web technologies (A specific type of distributed systems)
Active Server Pages (ASP), also known as Classic ASP or ASP Classic, was Microsoft's first server-side script engine for dynamically generated web pages.
Copyright © 2002 ProsoftTraining. All rights reserved. JavaServer Pages.
A seminar on j2ee by saritha. s. What is J2EE J2EE (Java 2 Platform, Enterprise Edition) is a Java platform designed for the mainframe-scale computing.
ASP (Active Server Pages) by Bülent & Resul. Presentation Outline Introduction What is an ASP file? How does ASP work? What can ASP do? Differences Between.
An Introduction to JavaServer™ Pages Prepared by Nicole Swan.
Middleware 3/29/2001 Kang, Seungwoo Lee, Jinwon. Description of Topics 1. CGI, Servlets, JSPs 2. Sessions/Cookies 3. Database Connection(JDBC, Connection.
CS562 Advanced Java and Internet Application Introduction to the Computer Warehouse Web Application. Java Server Pages (JSP) Technology. By Team Alpha.
Basic JSP Celsina Bignoli Problems with Servlets Servlets contain –request processing, –business logic –response generation all lumped.
ASP. ASP is a powerful tool for making dynamic and interactive Web pages An ASP file can contain text, HTML tags and scripts. Scripts in an ASP file are.
STRUCTURE OF JSP PRESENTED BY: SIDDHARTHA SINGH ( ) SOMYA SHRIVASTAV ( ) SONAM JINDAL ( )
©SoftMoore ConsultingSlide 1 Overview of Servlets and JavaServer Pages (JSP)
CSI 3125, Preliminaries, page 1 JSP (Java Server Pages)
1 Java Server Pages A Java Server Page is a file consisting of HTML or XML markup into which special tags and code blocks are inserted When the page is.
Chapter 6 Chapter 6 Server Side Programming (JSP) Part 1 1 (IS 203) WebProgramming (IS 203) Web Programming.
JAVA SERVER PAGES -by Rubeena Memon Deepti Jain Jaya Thakar Jisha Vettuventra.
Java Programming: Advanced Topics 1 Building Web Applications Chapter 13.
Java Server Pages. 2 Servlets The purpose of a servlet is to create a Web page in response to a client request Servlets are written in Java, with a little.
Bayu Priyambadha, S.Kom. Static content  Web Server delivers contents of a file (html) 1. Browser sends request to Web Server 3. Web Server sends HTML.
Web Page Designing With Dreamweaver MX\Session 1\1 of 9 Session 1 Introduction to PHP Hypertext Preprocessor - PHP.
JSP / Servlets and Beans
A Presentation Presentation On JSP On JSP & Online Shopping Cart Online Shopping Cart.
A S P. Outline  The introduction of ASP  Why we choose ASP  How ASP works  Basic syntax rule of ASP  ASP’S object model  Limitations of ASP  Summary.
Java Server Pages Can web pages be created specially for each user?
Introduction Servlets and JSP
Introduction and Principles
Introduction to JSP Liu Haibin 12/09/2018.
MSIS 655 Advanced Business Applications Programming
Java Server Pages (JSP)
Presentation transcript:

An Introduction to JavaServer™ Pages Prepared by Nicole Swan

General JSP Information Most Common JSP Components –Static HTML/XML components –Special JSP tags –Optionally, snippets of code written in Java called “scriptlets” JSPs are parsed on the server side –Translation phase occurs only once unless JSP is updated –Compiled class is then served to each client upon request

Advantages of JSP Separation of static from dynamic content Write once run anywhere Dynamic content can be served in a variety of formats Recommended web access layer for n-tier architecture Completely leverages the Servlet API (Source: )

JSP vs. ASP (Source: ) JSPASP Web Server Support Most popular web servers including Apache, Netscape, Microsoft IIS. Native support only within Microsoft IIS or Personal Web Server. Platform Support Platform independent. Runs on all Java-enabled platforms. Is fully supported under Windows. Component Model Reusable, cross-platform components like JavaBeans, EJB, and custom tag libraries. Uses the Win32-based COM component model. ScriptingJava or JavaScript. Supports VBScript and JScript for scripting. SecurityJava security model. Windows NT security architecture. Database AccessJDBC Active Data Objects Customizable Tags Extensible with custom tag libraries. Not extensible and cannot use custom tag libraries.

Basic JSP Syntax Directives Declarations Expressions Comments Scriptlets

Directives page directives are found at the top of most JSP pages. Specify java packages to include, the page language type, or the content type. Examples

Directives include directives are used to include static html content or other JSP content. Example

Declarations Declarations are found within the tag. Anything within this tag must be valid Java code including all appropriate syntax. Example <%! public void foo(){ out.println( i ); } %>

Expressions With expressions, the result of evaluating the expression is directly included in the output of the JSP page. Examples

Comments JSP comments are enclosed in the tag. Any comments in this format are not viewable when viewing the page’s source in a browser. Example Note: Can still use HTML comments though they are viewable to client

Scriptlets Scriptlets are used to embed code fragments within a JSP page. The tag is used. Example ”>

JSP Tag Libraries Allow Java developers to decouple static HTML and complex server-side behaviors In a sense, are a replacement for scriptlets Required use by many companies in JSP development Example true Condition was true Condition was false

JavaBeans JavaBeans topic is broad and complex For our purposes, allow JSP developers to decouple static HTML and complex server- side behaviors through the use of classes

JSP Development Environments Forte for Java (Community or Enterprise edition) –Provides syntax coloring which is nice Notepad –Simple and readily available WYSIWYG environments –Macromedia DreamWeaver –Adobe GoLive Macromedia ColdFusion Studio

Web Servers/Servlet Containers Apache Tomcat (Open Source) – Jetty (Open Source) – Bajie (free) – –Created by student at University of Texas – Dallas Various third-party servlet containers for various web servers –

Tomcat Servlet Container Can run as standalone web server Can serve static HTML as well as dynamic JSP content

Installing and Running Tomcat Download from tomcat-4.0/release/v4.1.18/bin/ tomcat-4.0/release/v4.1.18/bin/ Using WinZip (or some other similar tool) extract contents to C:\ (or wherever you choose) Set environmental variables (see handout) Start it up! (see handout) Check to see that it was installed properly (see handout)

Additional JSP Resources JSP Tutorial – Java Developer Connection – JavaServer™ Pages – JSP Syntax Reference – Google

Questions & Comments?