18.04.2013 Views

B2B Integration : A Practical Guide to Collaborative E-commerce

B2B Integration : A Practical Guide to Collaborative E-commerce

B2B Integration : A Practical Guide to Collaborative E-commerce

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Extensible Markup Language (XML) 175<br />

• Effective use of Internet — XML effectively uses the Internet <strong>to</strong><br />

transfer the messages securely; whereas most of the EDI message<br />

flow occurs through expensive VANs.<br />

6.5. XSL — Extensible Stylesheet Language<br />

In order <strong>to</strong> display XML documents, it is necessary <strong>to</strong> have a mechanism<br />

<strong>to</strong> describe how the document should be displayed. One of the commonly<br />

used presentation technologies is Cascading Style Sheets (CSS) used by<br />

HTML, but XSL (Extensible Stylesheet Language), the preferred style<br />

sheet language of XML, is far more sophisticated than CSS. XSL is a<br />

language that can transform XML in<strong>to</strong> multiple formats, a language that<br />

can filter, format and sort XML data and a language that uses XML as<br />

its syntax. Currently, XSL is used primarily <strong>to</strong> transform XML semantics<br />

in<strong>to</strong> a display format like HTML that can be viewed through Web<br />

browsers. However, XSL provides a wide variety of presentation layers<br />

for a single XML document.<br />

An XSL style sheet contains instructions as <strong>to</strong> how <strong>to</strong> pull out<br />

information from the XML document and transform it in<strong>to</strong> another<br />

format, such as HTML or PDF file. The transformation of XML in<strong>to</strong><br />

other formats is done in a declarative way rather than the conventional<br />

scripting way, which makes it much easier <strong>to</strong> understand and maintain.<br />

The browsers and devices such as PDAs (Personal Digital Assistants)<br />

and cell phones each have a unique display format. A single XML<br />

document can be presented on all these different presentation devices<br />

by using XSL. An XSL processor, either on the client or server, can<br />

transform XML data in<strong>to</strong> the appropriate format, thereby completely<br />

decoupling the business layer with the presentation layer. This separation<br />

is the key <strong>to</strong> building any flexible and extensible application.<br />

An XSL processor can have output in multiple formats taking XML<br />

and style sheets (DTDs, schemas) as the inputs (see Figure 6.3).<br />

XSL consists of the following three parts:<br />

• XML Vocabulary — It describes the formatting objects portion of<br />

XSL. The process of formatting is performed by the formatter. The<br />

formatter may simply be a rendering engine inside a browser.<br />

Formatting objects can be inserted in<strong>to</strong> a result tree created by

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!