|Oracle8i Application Developer's Guide - XML
Release 3 (8.1.7)
Part Number A86030-01
Customizing Discoverer 3i Viewer with XSL, 6 of 9
Discoverer 3i Viewer generates HTML by using the following XML components:
XSL configuration file (stylesheet) defines simple attributes, such as the fonts and colors to use, but it also defines the layout of each page, and the interactions with the user. By customizing the XSL stylesheet, specific Discoverer applications can be built and delivered on the Web.
After login, assume a Discoverer Viewer has asked for a list of workbooks that these workbooks are allowed to be opened in order to analyse their business. The URL issued is http://ukp14910.uk.oracle.com/disco/disco3iv?us=video&db=Disco
The URL specifies the machine the servlets are installed on, the username, and database connection string to use. The password is not normally shown on the URL for security reasons.
Discoverer 3i Viewer Servlet processes the URL. It instructs the Discoverer Application Server to check the security setting for this user and return details of the workbooks that this user is allowed to access.
Security settings are held in the End User Layer tables in the database. After this information is returned from the Discoverer Application Server, the servlet generates the following XML in which you can see information about the three workbooks being returned:
<?xml version="1.0" encoding="UTF-8"?> <?xml-stylesheet type="text/xsl" href="example1.xsl"?> <discoverer version="126.96.36.199" login_method="discoverer"> <account name="myname@mydatabase" ref="MYNAME%40mydatabase"> <user>MYNAME</user> <database>mydatabase</database> <eul default="true" name="myeul"> <workbook name="Store and Band Analysis" ref="Store~20and~20Band~20Analysis"> <description>Shows sales by Store, broken into sales bands</description> </workbook> <workbook name="Video Sales Analysis" ref="Video~20Sales~20Analysis"> <description>General purpose analysis of the business</description> </workbook> <workbook name="Annual Sales Report" ref="Annual~20Sales~20Report"> <description>Shows yearly and quarterly sales of products</description> </workbook> </eul> </account> </discoverer>
XSL is the industry standard stylesheet language defined by W3C. It allows a selection of elements from an XML file to be combined with an HTML template to generate HTML output for a Web Browser.
Discoverer 3i Viewer User Interface is entirely defined in XSL. This means it can be customized or copied to define alternative User Interface (UI) styles using standard Web development tools, such as HTML editors, XSL editors, or even simple text editors.
The XSL and XML .
Using the XML generated in Step 2 and the standard Discoverer 3i Viewer XSL configuration file (stylesheet), these are combined in the XSL-T processor in the XML Parser for Java,v2. This then generates the HTML version of the XML document.
This HTML is sent back to the browser in response to the initial URL.