Output production varies depending on the platform used to produce it. There are many different ways to create output, ranging from simple database software, such as Microsoft Access, to programs such as SAS, Crystal Reports, and Adobe Acrobat’s PDF files.
We discussed XML in Chapter 8. One of the advantages of using XML is that the XML document may be transformed into different output media types. This is done using cascading style sheets (CSSs) or extensible style language transformations (XSLTs). These methods reinforce the idea that data should be defined once and used many times in different formats.
Cascading style sheets are an easy way to transform an XML document. The style sheet provides a series of styles, such as font family, size, color, border, and so on, that are linked to the elements of the XML document. These styles may vary for different media, such as a screen, printed output, or a handheld device. The transforming software detects the type of device and applies the correct styles to control the output.
"IoT Activation 101: Bringing Data Intelligence to Every Corner of Your Building"Download now!
For example, a style used for a flat-panel display might use a rich palette of colors and a sans serif font, which is easier to read on a screen. A different style using a serif font and black or gray color may be used to define a printed report for the same data. A smaller font size might be used for a handheld device or mobile phone.
The drawback of using cascading style sheets is that they do not allow the analyst to manipulate the data, such as rearranging the order of the elements or sorting, and only a limited amount of identifying text, such as captions, may be added. They are basically used for formatting.
Extensible style language transformations (XSLT) are a more powerful means of transforming an XML document. They allow the analyst to select the elements and insert them into a Web page or another output medium. First figure shown below illustrates the transformation process. XSLT is not a programming language, but uses a series of statements to define which elements should be output, the sort sequence, the selection of data, and so on. An example of an XML transformation is illustrated in the send figure. The XML is shown on the left, and the result of the transformation is shown on the right. Notice that only the data between the tags (the tags are the less than  and greater than  symbols) are included in the output.
Ajax is discussed here because the output implications are important as well. It is up to the analyst and designer to determine when data should be added or changed on a Web page and to identify the conditions that cause the change. The order in which the questions are asked plays into this design as well.
An example of a Web page using Ajax is shown in the figure below, which demonstrates that Ajax makes it possible to display much less data on a page, thereby making the output less cluttered and less confusing. In this example, the user entered one of four ways to narrow down the search to view a list of current customers. The options the user had available were (1) enter the first three digits of a zip code (postal code), (2) enter a telephone area code, (3) select the state, or (4) select a country. The user may not know the postal code or area code and may therefore need to search by state or country, so the options are very useful.
After entering one of the location choices, in this case the first three digits of the postal code, the user clicked on the Get Customers button. The value of the postal code is sent to the server along with data indicating it was a postal code. The server then finds all customer records for the selected location, creates an XML document, and sends it to the same Web page.
When designing output, the systems analyst has many different options regarding how to display this data on the Web page. In this case, the analyst specified that the XML document would be used to create a drop-down list containing all current customers for the desired location. Once a user selects a customer from the drop-down list, more information about the particular customer is displayed, as shown in the example.
The advantage of using Ajax for displaying data is that the user does not have to wait for a new Web page to display after making a selection. The Ajax philosophy is to display limited questions for the user to answer on an incremental basis. This eliminates screen clutter. Once the user responds to an answer by making a choice, a new question may be generated.