Difference between revisions of "Web Application Creation Tutorial"

From PresenceWiki
Jump to: navigation, search
(Prerequisites)
(Part one: Task Creation)
Line 14: Line 14:
 
* Display a page showing information about the user's name
 
* Display a page showing information about the user's name
  
In a real world example both of these pages could be generated by a single Task, but we want to demonstrate multiple Tasks being used by a Web Application.
+
In a real world example both of these pages could be generated by a single Task, but we want to demonstrate multiple Tasks being used by a Web Application. The Tasks can be downloaded from [http://www.international-presence.com/wikidocs/samples/name_analysis.zip here]. Go ahead and extract the zip file then import the XML file into Presence.
  
# Create a new Category called "Name Analysis"
+
Once imported, you can test the functionality by running the [[Presence HTTP Server]] then directing your web browser to the following URL:
# Create a new Task in the Category called "Request Name"
+
# Create a new Task in the Category called "Analyse Name"
+
  
The Tasks can be downloaded from [http://www.international-presence.com/wikidocs/samples/Name_Analysis.xml here]. Go ahead and import them into Presence.
+
http://[server name]:[http port]/task/requestName
 +
 
 +
Try it out. You won't be very impressed, but if you can submit the form and receive a suitable response then it is working which is the main thing.
 +
 
 +
=== Part two: Web Application Creation ===
 +
 
 +
The next step is to create our WAR file which we will later deploy to our Servlet Engine.

Revision as of 07:56, 12 July 2010

This document describes the processes needed to create and deploy a Presence Web Application.

Prerequisites

For this tutorial you will need to install and run a Servlet Engine such as Tomcat:

Part one: Task Creation

For this example we will create a simple application that asks the user's name and then returns some information about the name. For this we will need two Tasks which:

  • Display a page requesting the user's name
  • Display a page showing information about the user's name

In a real world example both of these pages could be generated by a single Task, but we want to demonstrate multiple Tasks being used by a Web Application. The Tasks can be downloaded from here. Go ahead and extract the zip file then import the XML file into Presence.

Once imported, you can test the functionality by running the Presence HTTP Server then directing your web browser to the following URL:

http://[server name]:[http port]/task/requestName

Try it out. You won't be very impressed, but if you can submit the form and receive a suitable response then it is working which is the main thing.

Part two: Web Application Creation

The next step is to create our WAR file which we will later deploy to our Servlet Engine.