Overview of XMLHotelInfo PSP Application Sample
------------------------------------------------------
This Sample application describes how to create an XML output using
PSPs.
The PSP application provides an interface to select a hotel id and
then get corresponding
Hotel Details in XML form. The details displayed are: Room Type, Currency
and Rate.
Internet Explorer 5 supports XML documents. For Netscape, please setup
the mime type
for handle XML.
The user has to select a hotel id in main page by selecting a radio
button.
A button 'Get XML Hotel Information' should be pressed to see the hotel
selected
If not, the user is prompted to select a hotel id first. After selecting
a hotel id, press the
button 'Get XML Hotel Information '. This will display a psp page with
hotel selected
and another button 'Get XML Doc'. At the button press, Internet Explorer
is opened
to show the selected Hotel information in XML form.
Steps in the Sample :
---------------------
1) Invoke the application by opening the xmlmain page. This
will display the hotel ids and name
in a grid.
2) Select a hotel id by clicking on one of the radio buttons.
3) Now click the button: 'Get Hotel Details' below
4) If 'Get Hotel Details' button is pressed
without selecting a hotel id, then a message
is shown on the page: 'Please select
a hotel first'. Close button will close that page.
5) If 'Get Hotel Details' button is pressed
after selecting a hotel id, a different page pops up
showing the hotel selected; and a table
of hotel details. This is the normal PSP output.
Below this table are two buttons. One
is : 'Get XML Document' and other is 'Close'.
Close button will close the page. When
'Get XML Document' pressed, it opens up
Internet Explorer to show the
details of the selected Hotel details in XML form.
Description of Sample Files :
-----------------------------
The sample is provided as a zip file. This zip file contains all the
files required for the sample.
It contains the following files:
1) Install.html
- The steps to install the XMLHotelInfo PSP in the Oracle Database
2) Readme.html
- This file
3) XmlMain.psp
- Main page of the application displays 3 frames.
4) XmlTop.psp
- Displays the title in the Top frame of main page.
5) XmlBottom.psp
- Displays the button options available in the main page bottom frame.
6) HotelInfoForXml.psp
- Displays the list of Hotels in an HTML table as part of the main page.
7) SubmitForXml.psp
- Displays the Hotel information in HTML format and button to get the
XML form.
8) SqlToXml.psp
- Page receives XML request and and calls the XmlHotelInfo to display
the XML output.
9) XmlHotelInfo.psp
- Returns the XML output for the Hotel Information.
The steps in running the sample in iAS environment is explained below :
Running the sample using Oracle iAS:
--------------------------------------
Step 1. Install the PSP onto the Oracle database
using the instructions in the Install.html
Step 2. On the Application Server machine where
iAS is installed, create a Database Access
Descriptor(DAD) to connect to the schema where the PSP is installed in
Step 1.
Note: For details on creating DADs, refer to the document "Using mod_plsql"
on the Documentation Library CD-ROM of iAS software.
Step 3. After creating the DAD, access the
page by using a URL like:
http://<ipaddress>:<Port>/<virtual_path>/<dadname>/<PL/SQL
procedure name>
where,
<ipaddress> -> is the ip-address of the
machine on which iAS is setup
<Port>
-> is the port on which iAS http listener is setup to run
(refer to file $IAS_HOME/Apache/Apache/conf/httpds.conf)
<virtual_path> -> is the prefix defined for the PL/SQL module
(refer to file $IAS_HOME/Apache/modplsql/cfg/plsql.conf)
<dadname> -> is the name of the
DAD created in Step 2.
Example:
http://152.69.168.209:7890/pls/travel/xmlmain