Outline. CS 112 Introduction to Programming. Recap: HTML/CSS/Javascript. Admin. Outline

Save this PDF as:
 WORD  PNG  TXT  JPG

Size: px
Start display at page:

Download "Outline. CS 112 Introduction to Programming. Recap: HTML/CSS/Javascript. Admin. Outline"

Transcription

1 Outline CS 112 Introduction to Programming Web Programming: Backend (server side) Programming with Servlet, JSP q Admin and recap q Server-side web programming overview q Servlet programming q Java servlet page (JSP) Yang (Richard) Yang Computer Science Department Yale University 308A Watson, Phone: Admin q PS8 Part 2 (Bulldog tournament) Due Tuesday at 11:55 pm q Project checkpoint Due Thursday at 11:55 pm (Please use the CHECKPOINT template) Recap: HTML/CSS/Javascript q HTML: page content (model) Document object model (DOM) q CSS: display of content (view) q Javascript: interaction q Project demo day 11:30 12:30 pm Apr. 30 at TEAL 3 Outline q Admin and recap q Server-side web programming overview Web App--Server Side: Motivating Example (OPS2b) Madlib (template): One of the most <adjective> characters in fiction is named "Tarzan of the <plural-noun>." Tarzan was raised by a/an <noun> and lives in the <adjective> jungle in the heart of darkest <place>. He spends most of his time eating <plural-noun> and swinging from tree to <noun>. Whenever he gets angry, he beats on his chest and says, " <funny-noise>!" This is his war cry. Tarzan always dresses in <adjective> shorts made from the skin of a/an <noun> and his best friend is a/an <adjective> chimpanzee named Cheetah. He is supposed to be able to speak to elephants and <plural-noun>. In the movies, Tarzan is played by <person'sname>

2 Web App--Server Side: Motivating Example Commandline Madlib (interaction): Welcome to the game of Mad Libs. I will ask you to provide several words and phrases to fill in a mad lib story. Your mad-lib has been created: The result will be displayed to you. One of the most silly characters in fiction is named Template file? tarzan.txt "Tarzan of the apples." Tarzan was raised by a/an frisbee and lives in the hungry jungle in the Please input an adjective: silly heart of darkest New Haven, CT. He spends most of his time Please input a plural noun: apples eating bees and swinging from tree to umbrella. Please input a noun: frisbee Whenever he gets angry, he beats on his chest and says, Please input an adjective: hungry " burp!" This is his war cry. Tarzan always dresses in Please input a place: New Haven, CT shiny shorts made from the skin of a/an jelly donut Please input a plural noun: bees and his best friend is a/an beautiful chimpanzee named Please input a noun: umbrella Cheetah. He is supposed to be able to speak to elephants and Please input a funny noise: burp spoons. In the movies, Tarzan is played by Keanu Reeves. Please input an adjective: shiny Please input a noun: jelly donut Please input an adjective: beautiful Please input a plural noun: spoons pseudo code? Please input a person's name: Keanu Reeves 7 Cmdline Madlib Pseudo Code Ask user to choose story template Web presents a different medium to deliver app. The unit of interaction is Web page. Q: what Web pages? Webpage-Based Programming Input to Create Each Page? q One way to think about a dynamic Web page is to think it as an object: it is constructed with given input parameters q A Web page may collect input from user and then create another Web page (object)--browsing input P1 input P2 input P3 P1 P2 P3 Ask user to choose story template file Input: None Input Chosen template Who collect? Input User input for each token Chosen Template Who collect? Server-side Page Creation HTML Form q Form input parameter created html page Q: What is the mechanism in Web to collect user input? 2

3 HTML Form Program to be invoked Form Input Type q A form gives instruction to the browser on inputs to be collected from user URL (program) to be invoked when sending to server <form action="/create" method="get > Step 1: Please pick an input story template: <div> <input type="text" name="file" size ="40" value="tarzan.txt"> </div> <input type="hidden" name="language" value="english > <div> <input type="submit" value="next" /> </div> Invisible on page. Used </form> to pass internal data How input is transported to server: get/post An input item to be collected q <input type= text" name="q"> q <input type= checkbox name = myc /> q <input type= radio name = mypizzasize /> q <input type= range min= 0 max= 10 name = cheesiness /> q <select name="crust > <option value="thin">thin</option> <option value="thick">thick</option> <option value="cheese">cheese</option> </select> Web Execution Flow: Client Side q After user clicks submit on a form, browser encodes each input in a format <name>=<value> requests page with URL: Web Execution Flow: Server Side q Web server receives the request for the URL, finds the application for the URL, and passes the values of the parameters to the application q The application retrieves the parameters, generates a Web page, and sends the page back to the browser to display Google App Engine q A platform to simplify the development and hosting of Web applications Simplified deployment Load balancing Automatic scaling Useful high-level services and APIs 17 Discussion: What GAE can do to allow simple, flexible server-side app programming? q Client browser After user clicks submit on a form, browser encodes each input in a format <name>=<value> requests page with URL: q Web server receives the request for the URL, finds the application for the URL, and passes the values of the parameters to the application. web.xml: User defines URL mapping the application retrieves the request parameters, generates a response Web page back to the browser to display 3

4 Discussion: What GAE can do to allow simple, flexible server-side app programming? q Client browser After user clicks submit on a form, browser encodes each input in a format <name>=<value> requests page with URL: Define Servlet class: conduct q Web server common processing steps; app overrides receives the request for the URL, key step (doget/ finds the application for the URL, and dopost) to define app-specific behavior passes the values of the parameters to the application. the application retrieves the request parameters, generates a response Web page back to the browser to display Discussion: What GAE can do to allow simple, flexible server-side app programming? q Client browser After user clicks submit on a form, browser encodes each input in a format <name>=<value> requests page with URL: Define HttpServletRequest q Web server class to allow simple methods to retrieve receives the request for the URL, parameter, e.g., finds the application for the URL, getparameter( name ) and passes the values of the parameters to the application. the application retrieves the request parameters, generates a response Web page back to the browser to display Discussion: What GAE can do to allow simple, flexible server-side app programming? Example q Client browser After user clicks submit on a form, browser encodes each input in a format <name>=<value> requests page with URL: Define HttpServletResponse q Web server class to allow simple methods to write response receives the request for the URL, (not worry about sending finds the application for the URL, and across network), e.g., getwriter().println( passes the values of the parameters to <p>hello ) the application. the application retrieves the request parameters, generates a response Web page back to the browser to display Ask user to choose story template file Input: None index.html (see Note) web.xml Example Ask user to choose story template file <?xml version="1.0" encoding="utf-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemalocation="http://java.sun.com/xml/ns/javaee version="2.5 > <welcome-file-list> <welcome-file>index.html</welcome-file> </welcome-file-list> </web-app> 23 Input: Chosen template CreateMadlibServlet.java 4

5 web.xml q Allow a WebApp developer to declare the applications (servlets), and which servlet will serve which URL <?xml version="1.0" encoding="utf-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemalocation="http://java.sun.com/xml/ns/javaee version="2.5"> <servlet-class>madlibs.createmadlibservlet</servlet-class> <servlet-mapping> <url-pattern>/create</url-pattern> </servlet-mapping> <welcome-file-list> <welcome-file>index.html</welcome-file> </welcome-file-list> </web-app> 25 Example Ask user to choose story template file Input: User input for each token/template DisplayMadlibServlet.java web.xml q Allow a WebApp developer to declare the applications (servlets), and which servlet will serve which URL <?xml version="1.0" encoding="utf-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemalocation="http://java.sun.com/xml/ns/javaee version="2.5"> <servlet-class>madlibs.createmadlibservlet</servlet-class> <servlet-name>displaymadlibservlet</servlet-name> <servlet-class>madlibs.displaymadlibservlet</servlet-class> <servlet-mapping> <url-pattern>/create</url-pattern> </servlet-mapping> Outline q Admin and recap q Server-side programming overview q Java Servlet q Java Servlet Page (jsp) <servlet-mapping> <servlet-name>displaymadlibservlet</servlet-name> <url-pattern>/display</url-pattern> </servlet-mapping> <welcome-file-list> <welcome-file>index.html</welcome-file> </welcome-file-list> </web-app> Motivation q Most used statement in CreateMadlibServlet.java? Motivation q For many Web pages, most of the content will be static, and hence only a small portion will be generated dynamically q The Servlet architecture asks you to print the whole document (i.e., a large number of Java print and escape statements for printing the static part) 29 q JSP goal: remove most of the print statements 30 5

6 Motivating Example Manual HTML q Generate an html page consisting of a list of 10 random numbers 31 <li>1: 9</li> <li>2: 3</li> <li>3: 5</li> <li>4: 1</li> <li>5: 7</li> <li>6: 4</li> <li>7: 0</li> <li>8: 2</li> <li>9: 8</li> <li>10: 9</li> 32 Servlet JSP Motivation import java.util.random; public class NumListServlet extends HttpServlet { public void dopost(httpservletrequest req, HttpServletResponse resp) throws IOException { doget(req, resp); public void doget(httpservletrequest req, HttpServletResponse resp) throws IOException { resp.setcontenttype("text/html"); import java.util.random; public class NumListServlet extends HttpServlet { public void dopost(httpservletrequest req, HttpServletResponse resp) throws IOException { doget(req, resp); public void doget(httpservletrequest req, HttpServletResponse resp) throws IOException { resp.setcontenttype("text/html"); resp.getwriter().println(""); resp.getwriter().println(""); resp.getwriter().println( "); resp.getwriter().println(""); resp.getwriter().print( <li>"); resp.getwriter().print( i + : + rand.nextint(10) ); resp.getwriter().println("</li>"); resp.getwriter().println(""); resp.getwriter().println(""); resp.getwriter().println(""); resp.getwriter().println( "); resp.getwriter().println(""); resp.getwriter().print( <li>"); resp.getwriter().print(i + : + rand.nextint(10) ); resp.getwriter().println("</li>"); resp.getwriter().println(""); resp.getwriter().println(""); resp.getwriter().println(""); 33 resp.getwriter().println(""); resp.getwriter().println(""); 34 JSP Motivation Directive Run test.jsp as page contenttype="text/html;charset=utf-8" page import= java.util.random" resp.getwriter().print( <li>"); Called a JSP scriptlet, containing a fragment of java code resp.getwriter().print(i + : + rand.nextint(10) ); resp.getwriter().println("</li>"); Why it does not work?

7 web.xml <?xml version="1.0" encoding="utf-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemalocation="http://java.sun.com/xml/ns/javaee version="2.5"> <servlet-class>madlibs.createmadlibservlet</servlet-class> <servlet-name>displaymadlibservlet</servlet-name> <servlet-class>madlibs.displaymadlibservlet</servlet-class> <servlet-name>testjsp</servlet-name> <jsp-file>test.jsp</jsp-file> <servlet-mapping> <servlet-name>testjsp</servlet-name> <url-pattern>/test</url-pattern> </servlet-mapping>... <welcome-file-list> <welcome-file>index.html</welcome-file> </welcome-file-list> </web-app> JSP page contenttype="text/html;charset=utf-8" page import= java.util.random" response.getwriter().print( <li>"); Directive Called a JSP scriptlet, containing a fragment of java code response.getwriter().print(i + : + rand.nextint(10) ); response.getwriter().println("</li>"); implicit object See for implicit objects Output Problem Use implicit object out to print. out!= page contenttype="text/html;charset=utf-8" page import= java.util.random" response.getwriter().print( <li>"); response.getwriter().print(i + : + rand.nextint(10) ); response.getwriter().println("</li>"); Fix page contenttype="text/html;charset=utf-8" page import= java.util.random" out.print( <li>"); out.print(i + : + rand.nextint(10) ); page contenttype="text/html;charset=utf-8" page import= java.util.random" out.print( <li>"); out.print(i + : + rand.nextint(10) ); out.println("</li>"); What if we do not want to use the print statement?

8 Attempt JSP page contenttype="text/html;charset=utf-8" page import= java.util.random" <li> i : rand.nextint(10) </li> Problem: i and rand.nextint(10) are not treated as Java page contenttype="text/html;charset=utf-8" page import= java.util.random" <li> = i : = rand.nextint(10) </li> = encloses JSP expression, whose value appears in the output to out Motivation: Reduce Embedded page contenttype="text/html;charset=utf-8" page import= java.util.random <li> = i : = rand.nextint(10) </li> JSTL (JavaServer Pages Stanard Tag Library) q Objective: introduce JSP tags for common tasks such as conditional execution, loops, XML data access Motivation: Reduce Embedded page contenttype="text/html;charset=utf-8" taglib uri="http://java.sun.com/jsp/jstl/core" page import= java.util.random <c:foreach var="i" begin="1" end= 10"> <li> <c:out value="${i"/> = rand.nextint(10) </li> </c:foreach> Java Servlet Page (JSP) q History Released in 1999 Similar to PHP but supports more sophisticated J2EE programming q Can be considered as a high-level abstraction of Java servlets q In real implementation, JSPs are translated to servlets at runtime

9 Exercise q Turn CreateMadlibServlet.java into createmadlib.jsp 49 9

15-415 Database Applications Recitation 10. Project 3: CMUQFlix CMUQ s Movies Recommendation System

15-415 Database Applications Recitation 10. Project 3: CMUQFlix CMUQ s Movies Recommendation System 15-415 Database Applications Recitation 10 Project 3: CMUQFlix CMUQ s Movies Recommendation System Project Objective 1. Set up a front-end website with PostgreSQL back-end 2. Allow users to login, like

More information

Web Container Components Servlet JSP Tag Libraries

Web Container Components Servlet JSP Tag Libraries Web Application Development, Best Practices by Jeff Zhuk, JavaSchool.com ITS, Inc. dean@javaschool.com Web Container Components Servlet JSP Tag Libraries Servlet Standard Java class to handle an HTTP request

More information

Web Programming: Announcements. Sara Sprenkle August 3, 2006. August 3, 2006. Assignment 6 due today Project 2 due next Wednesday Review XML

Web Programming: Announcements. Sara Sprenkle August 3, 2006. August 3, 2006. Assignment 6 due today Project 2 due next Wednesday Review XML Web Programming: Java Servlets and JSPs Sara Sprenkle Announcements Assignment 6 due today Project 2 due next Wednesday Review XML Sara Sprenkle - CISC370 2 1 Web Programming Client Network Server Web

More information

2. Follow the installation directions and install the server on ccc

2. Follow the installation directions and install the server on ccc Installing a Web Server 1. Install a sample web server, which supports Servlets/JSPs. A light weight web server is Apache Tomcat server. You can get the server from http://tomcat.apache.org/ 2. Follow

More information

Introduction to J2EE Web Technologies

Introduction to J2EE Web Technologies Introduction to J2EE Web Technologies Kyle Brown Senior Technical Staff Member IBM WebSphere Services RTP, NC brownkyl@us.ibm.com Overview What is J2EE? What are Servlets? What are JSP's? How do you use

More information

Creating Java EE Applications and Servlets with IntelliJ IDEA

Creating Java EE Applications and Servlets with IntelliJ IDEA Creating Java EE Applications and Servlets with IntelliJ IDEA In this tutorial you will: 1. Create IntelliJ IDEA project for Java EE application 2. Create Servlet 3. Deploy the application to JBoss server

More information

Web Programming II JSP (Java Server Pages) ASP request processing. The Problem. The Problem. Enterprise Application Development using J2EE

Web Programming II JSP (Java Server Pages) ASP request processing. The Problem. The Problem. Enterprise Application Development using J2EE Enterprise Application Development using J2EE Shmulik London Lecture #6 Web Programming II JSP (Java Server Pages) How we approached it in the old days (ASP) Multiplication Table Multiplication

More information

An Introduction to J2EE by Mark Johnson

An Introduction to J2EE by Mark Johnson An Introduction to J2EE by Mark Johnson The Java 2, Enterprise Edition (J2EE) platform has been a global market-leading enterprise platform for the past several years. But like any large technology, J2EE

More information

Building Web Applications, Servlets, JSP and JDBC

Building Web Applications, Servlets, JSP and JDBC Building Web Applications, Servlets, JSP and JDBC Overview Java 2 Enterprise Edition (JEE) is a powerful platform for building web applications. The JEE platform offers all the advantages of developing

More information

Usability. Usability

Usability. Usability Objectives Review Usability Web Application Characteristics Review Servlets Deployment Sessions, Cookies Usability Trunk Test Harder than you probably thought Your answers didn t always agree Important

More information

BAPI. Business Application Programming Interface. Compiled by Y R Nagesh 1

BAPI. Business Application Programming Interface. Compiled by Y R Nagesh 1 BAPI Business Application Programming Interface Compiled by Y R Nagesh 1 What is BAPI A Business Application Programming Interface is a precisely defined interface providing access process and data in

More information

Application Security

Application Security 2009 Marty Hall Declarative Web Application Security Originals of Slides and Source Code for Examples: http://courses.coreservlets.com/course-materials/msajsp.html Customized Java EE Training: http://courses.coreservlets.com/

More information

Java EE Introduction, Content. Component Architecture: Why and How Java EE: Enterprise Java

Java EE Introduction, Content. Component Architecture: Why and How Java EE: Enterprise Java Java EE Introduction, Content Component Architecture: Why and How Java EE: Enterprise Java The Three-Tier Model The three -tier architecture allows to maintain state information, to improve performance,

More information

In this chapter, we lay the foundation for all our further discussions. We start

In this chapter, we lay the foundation for all our further discussions. We start 01 Struts.qxd 7/30/02 10:23 PM Page 1 CHAPTER 1 Introducing the Jakarta Struts Project and Its Supporting Components In this chapter, we lay the foundation for all our further discussions. We start by

More information

Hello World RESTful web service tutorial

Hello World RESTful web service tutorial Hello World RESTful web service tutorial Balázs Simon (sbalazs@iit.bme.hu), BME IIT, 2015 1 Introduction This document describes how to create a Hello World RESTful web service in Eclipse using JAX-RS

More information

<option> eggs </option> <option> cheese </option> </select> </p> </form>

<option> eggs </option> <option> cheese </option> </select> </p> </form> FORMS IN HTML A form is the usual way information is gotten from a browser to a server HTML has tags to create a collection of objects that implement this information gathering The objects are called widgets

More information

JSP Java Server Pages

JSP Java Server Pages JSP - Java Server Pages JSP Java Server Pages JSP - Java Server Pages Characteristics: A way to create dynamic web pages, Server side processing, Based on Java Technology, Large library base Platform independence

More information

Development of Web Applications

Development of Web Applications Development of Web Applications Principles and Practice Vincent Simonet, 2013-2014 Université Pierre et Marie Curie, Master Informatique, Spécialité STL 3 Server Technologies Vincent Simonet, 2013-2014

More information

Servlets. Based on Notes by Dave Hollinger & Ethan Cerami Also, the Online Java Tutorial by Sun

Servlets. Based on Notes by Dave Hollinger & Ethan Cerami Also, the Online Java Tutorial by Sun Servlets Based on Notes by Dave Hollinger & Ethan Cerami Also, the Online Java Tutorial by Sun 1 What is a Servlet? A Servlet is a Java program that extends the capabilities of servers. Inherently multi-threaded.

More information

2.8. Session management

2.8. Session management 2.8. Session management Juan M. Gimeno, Josep M. Ribó January, 2008 Session management. Contents Motivation Hidden fields URL rewriting Cookies Session management with the Servlet/JSP API Examples Scopes

More information

Complete Java Web Development

Complete Java Web Development Complete Java Web Development JAVA-WD Rev 11.14 4 days Description Complete Java Web Development is a crash course in developing cutting edge Web applications using the latest Java EE 6 technologies from

More information

ACM Crossroads Student Magazine The ACM's First Electronic Publication

ACM Crossroads Student Magazine The ACM's First Electronic Publication Page 1 of 8 ACM Crossroads Student Magazine The ACM's First Electronic Publication Crossroads Home Join the ACM! Search Crossroads crossroads@acm.org ACM / Crossroads / Columns / Connector / An Introduction

More information

Outline. Lecture 9: Java Servlet and JSP. Servlet API. HTTP Servlet Basics. User-defined Servlets. doget() and dopost()

Outline. Lecture 9: Java Servlet and JSP. Servlet API. HTTP Servlet Basics. User-defined Servlets. doget() and dopost() Lecture 9: Java Servlet and JSP Wendy Liu CSC309F Fall 2007 Outline HTTP Servlet Basics Servlet Lifecycle Request and Response Session Management JavaServer Pages (JSP) 1 2 HTTP Servlet Basics Current

More information

Developing XML Solutions with JavaServer Pages Technology

Developing XML Solutions with JavaServer Pages Technology Developing XML Solutions with JavaServer Pages Technology XML (extensible Markup Language) is a set of syntax rules and guidelines for defining text-based markup languages. XML languages have a number

More information

Course Name: Course in JSP Course Code: P5

Course Name: Course in JSP Course Code: P5 Course Name: Course in JSP Course Code: P5 Address: Sh No BSH 1,2,3 Almedia residency, Xetia Waddo Duler Mapusa Goa E-mail Id: ITKP@3i-infotech.com Tel: (0832) 2465556 (0832) 6454066 Course Code: P5 3i

More information

Programming on the Web(CSC309F) Tutorial: Servlets && Tomcat TA:Wael Aboelsaadat

Programming on the Web(CSC309F) Tutorial: Servlets && Tomcat TA:Wael Aboelsaadat Programming on the Web(CSC309F) Tutorial: Servlets && Tomcat TA:Wael Aboelsaadat Acknowledgments : This tutorial is based on a series of articles written by James Goodwill about Tomcat && Servlets. 1 Tomcat

More information

COMP201 Java Programming

COMP201 Java Programming COMP201 Java Programming Part III: Advanced Features Topic 14: Servlets Servlets and JavaServer Pages (JSP) 1.0: A Tutorial http://www.apl.jhu.edu/~hall/java/servlet-tutorial/servlet-tutorial-intro.html

More information

Servlet 3.0. Alexis Moussine-Pouchkine. mercredi 13 avril 2011

Servlet 3.0. Alexis Moussine-Pouchkine. mercredi 13 avril 2011 Servlet 3.0 Alexis Moussine-Pouchkine 1 Overview Java Servlet 3.0 API JSR 315 20 members Good mix of representation from major Java EE vendors, web container developers and web framework authors 2 Overview

More information

HTML Form Widgets. Review: HTML Forms. Review: CGI Programs

HTML Form Widgets. Review: HTML Forms. Review: CGI Programs HTML Form Widgets Review: HTML Forms HTML forms are used to create web pages that accept user input Forms allow the user to communicate information back to the web server Forms allow web servers to generate

More information

CrownPeak Java Web Hosting. Version 0.20

CrownPeak Java Web Hosting. Version 0.20 CrownPeak Java Web Hosting Version 0.20 2014 CrownPeak Technology, Inc. All rights reserved. No part of this document may be reproduced or transmitted in any form or by any means, electronic or mechanical,

More information

Agenda. Summary of Previous Session. Application Servers G22.3033-011. Session 3 - Main Theme Page-Based Application Servers (Part II)

Agenda. Summary of Previous Session. Application Servers G22.3033-011. Session 3 - Main Theme Page-Based Application Servers (Part II) Application Servers G22.3033-011 Session 3 - Main Theme Page-Based Application Servers (Part II) Dr. Jean-Claude Franchitti New York University Computer Science Department Courant Institute of Mathematical

More information

Controlling Web Application Behavior

Controlling Web Application Behavior 2006 Marty Hall Controlling Web Application Behavior The Deployment Descriptor: web.xml JSP, Servlet, Struts, JSF, AJAX, & Java 5 Training: http://courses.coreservlets.com J2EE Books from Sun Press: http://www.coreservlets.com

More information

Getting Started with Web Applications

Getting Started with Web Applications 3 Getting Started with Web Applications A web application is a dynamic extension of a web or application server. There are two types of web applications: Presentation-oriented: A presentation-oriented

More information

Announcements. Comments on project proposals will go out by email in next couple of days...

Announcements. Comments on project proposals will go out by email in next couple of days... Announcements Comments on project proposals will go out by email in next couple of days... 3-Tier Using TP Monitor client application TP monitor interface (API, presentation, authentication) transaction

More information

WIRIS quizzes web services Getting started with PHP and Java

WIRIS quizzes web services Getting started with PHP and Java WIRIS quizzes web services Getting started with PHP and Java Document Release: 1.3 2011 march, Maths for More www.wiris.com Summary This document provides client examples for PHP and Java. Contents WIRIS

More information

An introduction to web programming with Java

An introduction to web programming with Java Chapter 1 An introduction to web programming with Java Objectives Knowledge Objectives (continued) The first page of a shopping cart application The second page of a shopping cart application Components

More information

3M Information Technology

3M Information Technology 3M Information Technology IT Customer Relationship Management Applications Web Services Toolkit User Guide Custom Web Lead Capture Submit Lead Last Updated: 23-FEB-07 Page 1 of 33 (Last Modified: 2/24/2007

More information

Servlet Basics Customized Java EE Training:

Servlet Basics Customized Java EE Training: 2012 Marty Hall Servlet Basics Originals of Slides and Source Code for Examples: http://courses.coreservlets.com/course-materials/csajsp2.html 2 2012 Marty Hall For live Java EE training, please see training

More information

Java Servlet 3.0. Rajiv Mordani Spec Lead

Java Servlet 3.0. Rajiv Mordani Spec Lead Java Servlet 3.0 Rajiv Mordani Spec Lead 1 Overview JCP Java Servlet 3.0 API JSR 315 20 members > Good mix of representation from major Java EE vendors, web container developers and web framework authors

More information

JBoss Portlet Container. User Guide. Release 2.0

JBoss Portlet Container. User Guide. Release 2.0 JBoss Portlet Container User Guide Release 2.0 1. Introduction.. 1 1.1. Motivation.. 1 1.2. Audience 1 1.3. Simple Portal: showcasing JBoss Portlet Container.. 1 1.4. Resources. 1 2. Installation. 3 2.1.

More information

PA165 - Lab session - Web Presentation Layer

PA165 - Lab session - Web Presentation Layer PA165 - Lab session - Web Presentation Layer Author: Martin Kuba Goal Experiment with basic building blocks of Java server side web technology servlets, filters, context listeners,

More information

Complete Java Web Development INT2201; 4 Days; Instructor-led

Complete Java Web Development INT2201; 4 Days; Instructor-led Complete Java Web Development INT2201; 4 Days; Instructor-led Course Description Complete Java Web Development is a crash course in developing cutting edge Web applications using the latest Java EE 6 technologies

More information

PowerTier Web Development Tools 4

PowerTier Web Development Tools 4 4 PowerTier Web Development Tools 4 This chapter describes the process of developing J2EE applications with Web components, and introduces the PowerTier tools you use at each stage of the development process.

More information

JAHIA CMS AND PORTAL SERVER

JAHIA CMS AND PORTAL SERVER Computer Practie JAHIA CMS AND PORTAL SERVER Web Application Developer Guide DRAFT VERSION Serge Huber Jahia Ltd 1.0 english Jahia Ltd 45, rue de la Gare 1260 Nyon Switzerland i Disclaimers, Terms and

More information

Pure server-side Web Applications with Java, JSP. Application Servers: the Essential Tool of Server-Side Programming. Install and Check Tomcat

Pure server-side Web Applications with Java, JSP. Application Servers: the Essential Tool of Server-Side Programming. Install and Check Tomcat Pure server-side Web Applications with Java, JSP Discussion of networklevel http requests and responses Using the Java programming language (Java servlets and JSPs) Key lesson: The role of application

More information

SSC - Web development Model-View-Controller for Java web application development

SSC - Web development Model-View-Controller for Java web application development SSC - Web development Model-View-Controller for Java web application development Shan He School for Computational Science University of Birmingham Module 06-19321: SSC Outline Outline of Topics Java Server

More information

Outline. Lecture 9: Java Servlet and JSP. Servlet API. HTTP Servlet Basics

Outline. Lecture 9: Java Servlet and JSP. Servlet API. HTTP Servlet Basics Lecture 9: Java Servlet and JSP Wendy Liu CSC309F Fall 2007 Outline HTTP Servlet Basics Servlet Lifecycle Request and Response Session Management JavaServer Pages (JSP) 1 2 HTTP Servlet Basics Current

More information

DTS Web Developers Guide

DTS Web Developers Guide Apelon, Inc. Suite 202, 100 Danbury Road Ridgefield, CT 06877 Phone: (203) 431-2530 Fax: (203) 431-2523 www.apelon.com Apelon Distributed Terminology System (DTS) DTS Web Developers Guide Table of Contents

More information

Web Frameworks and WebWork

Web Frameworks and WebWork Web Frameworks and WebWork Problem area Mixing application logic and markup is bad practise Harder to change and maintain Error prone Harder to re-use public void doget( HttpServletRequest request, HttpServletResponse

More information

Developing Web Applications using JavaServer Pages and Servlets

Developing Web Applications using JavaServer Pages and Servlets Redpaper Martin Keen Rafael Coutinho Sylvi Lippmann Salvatore Sollami Sundaragopal Venkatraman Steve Baber Henry Cui Craig Fleming Developing Web Applications using JavaServer Pages and Servlets This IBM

More information

Glassfish, JAVA EE, Servlets, JSP, EJB

Glassfish, JAVA EE, Servlets, JSP, EJB Glassfish, JAVA EE, Servlets, JSP, EJB Java platform A Java platform comprises the JVM together with supporting class libraries. Java 2 Standard Edition (J2SE) (1999) provides core libraries for data structures,

More information

INTRODUCTION TO WEB TECHNOLOGY

INTRODUCTION TO WEB TECHNOLOGY UNIT-I Introduction to Web Technologies: Introduction to web servers like Apache1.1, IIS, XAMPP (Bundle Server), WAMP Server(Bundle Server), handling HTTP Request and Response, installation of above servers

More information

Recommended readings. Lecture 11 - Securing Web. Applications. Security. Declarative Security

Recommended readings. Lecture 11 - Securing Web. Applications. Security. Declarative Security Recommended readings Lecture 11 Securing Web http://www.theserverside.com/tt/articles/content/tomcats ecurity/tomcatsecurity.pdf http://localhost:8080/tomcat-docs/security-managerhowto.html http://courses.coreservlets.com/course-

More information

01KPS BF Progettazione di applicazioni web

01KPS BF Progettazione di applicazioni web 01KPS BF Progettazione di applicazioni web Servlets in the J2EE platform Fulvio Corno Dipartimento di Automatica e Informatica Politecnico di Torino PAW - HTTP Servlets 1 The J2EE Presentation tier Servlets

More information

In order for the form to process and send correctly the follow objects must be in the form tag.

In order for the form to process and send correctly the follow objects must be in the form tag. Creating Forms Creating an email form within the dotcms platform, all the HTML for the form must be in the Body field of a Content Structure. All names are case sensitive. In order for the form to process

More information

Question No :1 Name the class that includes the getsession method that is used to get the HttpSession object (Choose correct one from multiple below)

Question No :1 Name the class that includes the getsession method that is used to get the HttpSession object (Choose correct one from multiple below) Question No :1 Name the class that includes the getsession method that is used to get the HttpSession object 1. HttpServletRequest 2. HttpServletResponse 3. SessionContext 4. SessionConfig Explanations

More information

c. Write a JavaScript statement to print out as an alert box the value of the third Radio button (whether or not selected) in the second form.

c. Write a JavaScript statement to print out as an alert box the value of the third Radio button (whether or not selected) in the second form. Practice Problems: These problems are intended to clarify some of the basic concepts related to access to some of the form controls. In the process you should enter the problems in the computer and run

More information

An introduction to creating JSF applications in Rational Application Developer Version 8.0

An introduction to creating JSF applications in Rational Application Developer Version 8.0 An introduction to creating JSF applications in Rational Application Developer Version 8.0 September 2010 Copyright IBM Corporation 2010. 1 Overview Although you can use several Web technologies to create

More information

TCP/IP Networking, Part 2: Web-Based Control

TCP/IP Networking, Part 2: Web-Based Control TCP/IP Networking, Part 2: Web-Based Control Microchip TCP/IP Stack HTTP2 Module 2007 Microchip Technology Incorporated. All Rights Reserved. Building Embedded Web Applications Slide 1 Welcome to the next

More information

Exam Prep. Sun Certified Web Component Developer (SCWCD) for J2EE Platform

Exam Prep. Sun Certified Web Component Developer (SCWCD) for J2EE Platform Exam Prep Sun Certified Web Component Developer (SCWCD) for J2EE Platform Core Servlets & JSP book: www.coreservlets.com More Servlets & JSP book: www.moreservlets.com Servlet and JSP Training Courses:

More information

Java Server Pages combined with servlets in action. Generals. Java Servlets

Java Server Pages combined with servlets in action. Generals. Java Servlets Java Server Pages combined with servlets in action We want to create a small web application (library), that illustrates the usage of JavaServer Pages combined with Java Servlets. We use the JavaServer

More information

Class Focus: Web Applications that provide Dynamic Content

Class Focus: Web Applications that provide Dynamic Content Class Focus: Web Applications that provide Dynamic Content We will learn how to build server-side applications that interact with their users and provide dynamic content Using the Java programming language

More information

Web Application Development Using Borland JBuilder 8 WebLogic Edition

Web Application Development Using Borland JBuilder 8 WebLogic Edition Web Application Development Using Borland JBuilder 8 WebLogic Edition Jumpstart development, deployment, and debugging servlets and JSP A Borland and BEA White Paper By Sudhansu Pati, Systems Engineer

More information

Web Application Architecture (based J2EE 1.4 Tutorial)

Web Application Architecture (based J2EE 1.4 Tutorial) Web Application Architecture (based J2EE 1.4 Tutorial) 1 Disclaimer & Acknowledgments Even though Sang Shin is a full-time employee of Sun Microsystems, the contents here are created as his own personal

More information

Mobile Web Applications. Gary Dubuque IT Research Architect Department of Revenue

Mobile Web Applications. Gary Dubuque IT Research Architect Department of Revenue Mobile Web Applications Gary Dubuque IT Research Architect Department of Revenue Summary Times are approximate 10:15am 10:25am 10:35am 10:45am Evolution of Web Applications How they got replaced by native

More information

Reporting and JSF. Possibilities, solutions, challenges. Slide 1. Copyright 2009, Andy Bosch, www.jsf-portlets.net

Reporting and JSF. Possibilities, solutions, challenges. Slide 1. Copyright 2009, Andy Bosch, www.jsf-portlets.net Reporting and JSF Possibilities, solutions, challenges Slide 1 Agenda What is reporting? Why do we need it? The JSF example application Introduction to reporting engines Overview Eclipse BIRT JasperReports

More information

Portals and Hosted Files

Portals and Hosted Files 12 Portals and Hosted Files This chapter introduces Progress Rollbase Portals, portal pages, portal visitors setup and management, portal access control and login/authentication and recommended guidelines

More information

Supplement IV.E: Tutorial for Tomcat. For Introduction to Java Programming By Y. Daniel Liang

Supplement IV.E: Tutorial for Tomcat. For Introduction to Java Programming By Y. Daniel Liang Supplement IV.E: Tutorial for Tomcat For Introduction to Java Programming By Y. Daniel Liang This supplement covers the following topics: Obtaining and Installing Tomcat Starting and Stopping Tomcat Choosing

More information

Oracle Hyperion Financial Management Developer and Customization Guide

Oracle Hyperion Financial Management Developer and Customization Guide Oracle Hyperion Financial Management Developer and Customization Guide CONTENTS Overview... 1 Financial Management SDK... 1 Prerequisites... 2 SDK Reference... 2 Steps for running the demo application...

More information

7 Web Databases. Access to Web Databases: Servlets, Applets. Java Server Pages PHP, PEAR. Languages: Java, PHP, Python,...

7 Web Databases. Access to Web Databases: Servlets, Applets. Java Server Pages PHP, PEAR. Languages: Java, PHP, Python,... 7 Web Databases Access to Web Databases: Servlets, Applets Java Server Pages PHP, PEAR Languages: Java, PHP, Python,... Prof. Dr. Dietmar Seipel 837 7.1 Access to Web Databases by Servlets Java Servlets

More information

CS387 Tutorial. Outline. Why Build Web Pages Dynamically? Building Internet Applications with Servlets and JSPs. Java Servlets JSP ASP PHP

CS387 Tutorial. Outline. Why Build Web Pages Dynamically? Building Internet Applications with Servlets and JSPs. Java Servlets JSP ASP PHP CS387 Tutorial Building Internet Applications with Servlets and JSPs Outline Java Servlets JSP ASP PHP Why Build Web Pages Dynamically? The Web page is based on data submitted by the user E.g., results

More information

Oracle Hyperion Financial Management Custom Pages Development Guide

Oracle Hyperion Financial Management Custom Pages Development Guide Oracle Hyperion Financial Management Custom Pages Development Guide CONTENTS Overview... 2 Custom pages... 2 Prerequisites... 2 Sample application structure... 2 Framework for custom pages... 3 Links...

More information

CS108, Stanford Handout #33 Young. HW5 Web

CS108, Stanford Handout #33 Young. HW5 Web CS108, Stanford Handout #33 Young HW5 Web In this assignment we ll build two separate web projects. This assignment is due the evening of Tuesday November 3 rd at Midnight. You cannot take late days on

More information

CREATE A CUSTOM THEME WEBSPHERE PORTAL 8.0.0.1

CREATE A CUSTOM THEME WEBSPHERE PORTAL 8.0.0.1 CREATE A CUSTOM THEME WEBSPHERE PORTAL 8.0.0.1 WITHOUT TEMPLATE LOCALIZATION, WITHOUT WEBDAV AND IN ONE WAR FILE Simona Bracco Table of Contents Introduction...3 Extract theme dynamic and static resources...3

More information

Lecture 10 Fundamentals of GAE Development. Cloud Application Development (SE808, School of Software, Sun Yat-Sen University) Yabo (Arber) Xu

Lecture 10 Fundamentals of GAE Development. Cloud Application Development (SE808, School of Software, Sun Yat-Sen University) Yabo (Arber) Xu Lecture 10 Fundamentals of GAE Development Cloud Application Development (SE808, School of Software, Sun Yat-Sen University) Yabo (Arber) Xu Outline GAE Architecture GAE Dev Environment Anatomy of GAE

More information

Java and Web. WebWork

Java and Web. WebWork Java and Web WebWork Client/Server server client request HTTP response Inside the Server (1) HTTP requests Functionality for communicating with clients using HTTP CSS Stat. page Dyn. page Dyn. page Our

More information

Accessing Data with ADOBE FLEX 4.6

Accessing Data with ADOBE FLEX 4.6 Accessing Data with ADOBE FLEX 4.6 Legal notices Legal notices For legal notices, see http://help.adobe.com/en_us/legalnotices/index.html. iii Contents Chapter 1: Accessing data services overview Data

More information

Model-View-Controller. and. Struts 2

Model-View-Controller. and. Struts 2 Model-View-Controller and Struts 2 Problem area Mixing application logic and markup is bad practise Harder to change and maintain Error prone Harder to re-use public void doget( HttpServletRequest request,

More information

Introduction to HTML HTML Tables and Forms HttpServlet Class. doget method dopost method. Generating and Processing Dynamic Forms with Java Servlets

Introduction to HTML HTML Tables and Forms HttpServlet Class. doget method dopost method. Generating and Processing Dynamic Forms with Java Servlets Introduction to HTML HTML Tables and Forms HttpServlet Class doget method dopost method Generating and Processing Dynamic Forms with Java Servlets HTML documents consist of ordinary text and tags. Tags

More information

Consuming and Producing Web Services with WST and JST. Christopher M. Judd. President/Consultant Judd Solutions, LLC

Consuming and Producing Web Services with WST and JST. Christopher M. Judd. President/Consultant Judd Solutions, LLC Consuming and Producing Web Services with WST and JST Christopher M. Judd President/Consultant Judd Solutions, LLC Christopher M. Judd President/Consultant of Judd Solutions Central Ohio Java User Group

More information

A Guide to Understanding Web Application Development Corey Benson, SAS Institute, Inc., Cary, NC Robert Girardin, SAS Institute, Inc.

A Guide to Understanding Web Application Development Corey Benson, SAS Institute, Inc., Cary, NC Robert Girardin, SAS Institute, Inc. Paper 024-29 A Guide to Understanding Web Application Development Corey Benson, SAS Institute, Inc., Cary, NC Robert Girardin, SAS Institute, Inc., Cary, NC ABSTRACT You have been asked by your manager

More information

Piotr Nowicki's Homepage. Java EE 6 SCWCD Mock Exam. "Simplicity is the ultimate sophistication." Important!

Piotr Nowicki's Homepage. Java EE 6 SCWCD Mock Exam. Simplicity is the ultimate sophistication. Important! Piotr Nowicki's Homepage "Simplicity is the ultimate sophistication." Java EE 6 SCWCD Mock Exam Posted on March 27, 2011 by Piotr 47 Replies Edit This test might help to test your knowledge before taking

More information

Client vs. Server Implementations of Mitigating XSS Security Threats on Web Applications

Client vs. Server Implementations of Mitigating XSS Security Threats on Web Applications Journal of Basic and Applied Engineering Research pp. 50-54 Krishi Sanskriti Publications http://www.krishisanskriti.org/jbaer.html Client vs. Server Implementations of Mitigating XSS Security Threats

More information

Search Engine Optimization for a WebSphere Commerce System

Search Engine Optimization for a WebSphere Commerce System IBM Software Group Search Engine Optimization for a WebSphere Commerce System Shash Anand (sanand@ca.ibm.com) Aileen Guan (aguan@ca.ibm.com) WebSphere Support Technical Exchange Agenda Overview General

More information

Viewing Form Results

Viewing Form Results Form Tags XHTML About Forms Forms allow you to collect information from visitors to your Web site. The example below is a typical tech suupport form for a visitor to ask a question. More complex forms

More information

Java 2 Web Developer Certification Study Guide Natalie Levi

Java 2 Web Developer Certification Study Guide Natalie Levi SYBEX Sample Chapter Java 2 Web Developer Certification Study Guide Natalie Levi Chapter 8: Thread-Safe Servlets Copyright 2002 SYBEX Inc., 1151 Marina Village Parkway, Alameda, CA 94501. World rights

More information

Web Design and Development ACS-1809. Chapter 13. Using Forms 11/30/2015 1

Web Design and Development ACS-1809. Chapter 13. Using Forms 11/30/2015 1 Web Design and Development ACS-1809 Chapter 13 Using Forms 11/30/2015 1 Chapter 13: Employing Forms Understand the concept and uses of forms in web pages Create a basic form Validate the form content 11/30/2015

More information

ASP.NET: THE NEW PARADIGM FOR WEB APPLICATION DEVELOPMENT

ASP.NET: THE NEW PARADIGM FOR WEB APPLICATION DEVELOPMENT ASP.NET: THE NEW PARADIGM FOR WEB APPLICATION DEVELOPMENT Dr. Mike Morrison, University of Wisconsin-Eau Claire, morriscm@uwec.edu Dr. Joline Morrison, University of Wisconsin-Eau Claire, morrisjp@uwec.edu

More information

SSC - Web applications and development Introduction and Java Servlet (II)

SSC - Web applications and development Introduction and Java Servlet (II) SSC - Web applications and development Introduction and Java Servlet (II) Shan He School for Computational Science University of Birmingham Module 06-19321: SSC Outline Outline of Topics Servlet Configuration

More information

The Architectural Design of FRUIT: A Family of Retargetable User Interface Tools

The Architectural Design of FRUIT: A Family of Retargetable User Interface Tools The Architectural Design of : A Family of Retargetable User Interface Tools Yi Liu Computer Science University of Mississippi University, MS 38677 H. Conrad Cunningham Computer Science University of Mississippi

More information

Maximize the value of your IT investments with Veryant

Maximize the value of your IT investments with Veryant Solutions Maximize the value of your IT investments with Veryant Veryant offers software, services, solutions, and strong alliances to help your business meet its goals. Select a subject area below to

More information

Web Development on the SOEN 6011 Server

Web Development on the SOEN 6011 Server Web Development on the SOEN 6011 Server Stephen Barret October 30, 2007 Introduction Systems structured around Fowler s patterns of Enterprise Application Architecture (EAA) require a multi-tiered environment

More information

JBoss SOAP Web Services User Guide. Version: 3.3.0.M5

JBoss SOAP Web Services User Guide. Version: 3.3.0.M5 JBoss SOAP Web Services User Guide Version: 3.3.0.M5 1. JBoss SOAP Web Services Runtime and Tools support Overview... 1 1.1. Key Features of JBossWS... 1 2. Creating a Simple Web Service... 3 2.1. Generation...

More information

Oracle WebLogic Server

Oracle WebLogic Server Oracle WebLogic Server Developing Web Applications, Servlets, and JSPs for Oracle WebLogic Server 10g Release 3 (10.3) July 2008 Oracle WebLogic Server Developing Web Applications, Servlets, and JSPs for

More information

Development. with NetBeans 5.0. A Quick Start in Basic Web and Struts Applications. Geertjan Wielenga

Development. with NetBeans 5.0. A Quick Start in Basic Web and Struts Applications. Geertjan Wielenga Web Development with NetBeans 5.0 Quick Start in Basic Web and Struts pplications Geertjan Wielenga Web Development with NetBeans 5 This tutorial takes you through the basics of using NetBeans IDE 5.0

More information

Web Programming with Java Servlets

Web Programming with Java Servlets Web Programming with Java Servlets Leonidas Fegaras University of Texas at Arlington Web Data Management and XML L3: Web Programming with Servlets 1 Database Connectivity with JDBC The JDBC API makes it

More information

Servlets and Java Server Pages. Prem Melville. The Machine Learning Group Department of Computer Sciences The University of Texas at Austin

Servlets and Java Server Pages. Prem Melville. The Machine Learning Group Department of Computer Sciences The University of Texas at Austin Servlets and Java Server Pages Prem Melville The Machine Learning Group Department of Computer Sciences The University of Texas at Austin UT-CS 8/24/01 1 What s a Servlet? Java s answer to CGI programming

More information

General principles and architecture of Adlib and Adlib API. Petra Otten Manager Customer Support

General principles and architecture of Adlib and Adlib API. Petra Otten Manager Customer Support General principles and architecture of Adlib and Adlib API Petra Otten Manager Customer Support Adlib Database management program, mainly for libraries, museums and archives 1600 customers in app. 30 countries

More information

CSCI110: Examination information.

CSCI110: Examination information. CSCI110: Examination information. The exam for CSCI110 will consist of short answer questions. Most of them will require a couple of sentences of explanation of a concept covered in lectures or practical

More information

Mastering Tomcat Development

Mastering Tomcat Development hep/ Mastering Tomcat Development Ian McFarland Peter Harrison '. \ Wiley Publishing, Inc. ' Part I Chapter 1 Chapter 2 Acknowledgments About the Author Introduction Tomcat Configuration and Management

More information