#RefreshCache Effective XSLT Making use of XSLT to better customize your data. Daniel Hazelbaker Information Technology Manager High Desert Church Email:

Slides:



Advertisements
Similar presentations
XML-XSL Introduction SHIJU RAJAN SHIJU RAJAN Outline Brief Overview Brief Overview What is XML? What is XML? Well Formed XML Well Formed XML Tag Name.
Advertisements

Advanced XSLT. Branching in XSLT XSLT is functional programming –The program evaluates a function –The function transforms one structure into another.
Advanced XSLT II. Iteration in XSLT we sometimes wish to apply the same transform to a set of nodes we iterate through a node set the node set is defined.
XSLT (eXtensible Stylesheet Language Transformation) 1.
XML: Managing Data Exchange Stylesheets. Lesson Contents CSS The basic XSL file XSL transforms Templates Sort Numbering Parameters and Variables Datatypes.
SDPL 2003Notes 5.1: Additional XPath & XSLT1 5.1 Additional features of XPath & XSLT n XPath support for –arithmetical operations –processing ID/IDREF.
2-Jun-15 XPath. 2 What is XPath? XPath is a syntax used for selecting parts of an XML document The way XPath describes paths to elements is similar to.
XSLT Stylesheets Some more advanced examples (adapted from the Edinburgh LT site)
XSLT & XPATH. From Friday Everything in XML is machine readable Attributes describe elements, so does an element’s place in the tree (context) XML must.
eXtensible Stylesheet Language
A note on generating text with the xsl:value-of instruction.
XP New Perspectives on XML, 2 nd Edition Tutorial 7 1 TUTORIAL 7 CREATING A COMPUTATIONAL STYLESHEET (Using XSLT style sheet to calculate values based.
XSL Transformations Transforming XML document into other (XML) documents 1XSL Transformations.
17 Apr 2002 XML Stylesheets Andy Clark. What Is It? Extensible Stylesheet Language (XSL) Language for document transformation – Transformation (XSLT)
MC 365 – Software Engineering Presented by: John Ristuccia Shawn Posts Ndi Sampson XSLT Introduction BCi.
CIS 375—Web App Dev II XPath. 2 XPath IntroductionIntroduction What is XPath? XPath is a syntax for defining parts of an _____ document XPath uses paths.
Overview of XPath Author: Dan McCreary Date: October, 2008 Version: 0.2 with TEI Examples M D.
Introduction to XPath Bun Yue Professor, CS/CIS UHCL.
XP ATH - XML Path Language. W HAT IS XP ATH ? XPath, the XML Path Language, is a query language for selecting nodes from an XML document.query languagenodesXML.
© 2011 LogiGear Corporation. All Rights Reserved Capturing Interface Presenter: Thuy Tran.
SDPL 2001Notes 5.1: Additional XPath & XSLT1 5.1 XPath & XSLT: Additional features n XPath support for –arithmetical operations –processing ID/IDREF cross-references.
ECA 228 Internet/Intranet Design I Intro to XSL. ECA 228 Internet/Intranet Design I XSL basics W3C standards for stylesheets – CSS – XSL: Extensible Markup.
JSP Standard Tag Library
Navigating XML. Overview  Xpath is a non-xml syntax to be used with XSLT and Xpointer. Its purpose according to the W3.org is  to address parts of an.
CSE3201/CSE4500 XPath. 2 XPath A locator for elements or attributes in an XML document. XPath expression gives direction.
XML DOCUMENTS & DATABASES. Summary of Introduction to XML HTML vs. XML HTML vs. XML Types of Data Types of Data Basics of XML Basics of XML XML Syntax,
CSE3201/CSE4500 Information Retrieval Systems
XSLT and XPath, by Dr. Khalil1 XSL, XSLT and XPath Dr. Awad Khalil Computer Science Department AUC.
1 XPath XPath became a W3C Recommendation 16. November 1999 XPath is a language for finding information in an XML document XPath is used to navigate through.
JQuery Adding behaviour…. Lecture Plan Review of last lesson Adding behaviour –click, mouseover Animation –fade, slideDown Navigation –parent, find, next.
Lucas Mak and Dao Rong Gong Michigan State University Millennium and XML: Repurposing and Customizing Metadata May , 2009.
1 CIS336 Website design, implementation and management (also Semester 2 of CIS219, CIS221 and IT226) Lecture 6 XSLT (Based on Møller and Schwartzbach,
XPath Kanda Runapongsa Dept. of Computer Engineering Khon Kaen University.
JSTL, XML and XSLT An introduction to JSP Standard Tag Library and XML/XSLT transformation for Web layout.
Extensible Stylesheet Language Chao-Hsien Chu, Ph.D. School of Information Sciences and Technology The Pennsylvania State University XSL-FO XSLT.
XSLT part of XSL (Extensible Stylesheet Language) –includes also XPath and XSL Formatting Objects used to transform an XML document into: –another XML.
XSLT Kanda Runapongsa Dept. of Computer Engineering Khon Kaen University.
More on XSLT 07. More on XSLT © Aptech Limited XPath  In this first lesson, XPath, you will learn to:  Define and describe XPath.  Identify nodes according.
IS432: Semi-Structured Data Dr. Azeddine Chikh. 6. XML Path (XPath)
SDPL 2002Notes 5.1: Additional XPath & XSLT1 5.1 Additional features of XPath & XSLT n XPath support for –arithmetical operations –processing ID/IDREF.
XPath Aug ’10 – Dec ‘10. XPath   XML Path Language   Technology that allows to select a part or parts of an XML document to process   XPath was.
XQuery Functions Reusing XQuery Code Date: September, 2008 Dan McCreary President Dan McCreary & Associates (952) M D Metadata.
 2002 Prentice Hall, Inc. All rights reserved. 1 Chapter 12 – XSL: Extensible Stylesheet Language Transformations (XSLT) Outline 12.1Introduction 12.2Setup.
McGraw-Hill/Irwin © 2004 by The McGraw-Hill Companies, Inc. All rights reserved. Applying eXtensible Style Sheets (XSL) Ellen Pearlman Eileen Mullin Programming.
ACG 6415 XSLT Presenting XML and XBRL. Re-Purpose  The main benefit of XML / XBRL Reusability of Data contained in Instance Document We need a method.
JSTL The JavaServer Pages Standard Tag Library (JSTL) is a collection of useful JSP tags which encapsulates core functionality common to many JSP applications.
Unit 3 — Advanced Internet Technologies Lesson 11 — Introduction to XSL.
XPath. XPath, the XML Path Language, is a query language for selecting nodes from an XML document. The XPath language is based on a tree representation.
 XSL – Extensible Style Sheet Language  XSLT – XSL Transformations › Used to transform XML documents to other formats,like HTML or other XML documents.
XP New Perspectives on XML, 2 nd Edition Tutorial 7 1 TUTORIAL 7 CREATING A COMPUTATIONAL STYLESHEET.
ACG 4401 XSLT Extensible Stylesheet Language for Transformations Presenting XML and XBRL.
CSE3201/CSE4500 XPath. 2 XPath A locator for items in XML document. XPath expression gives direction of navigation.
XPath --XML Path Language Motivation of XPath Data Model and Data Types Node Types Location Steps Functions XPath 2.0 Additional Functionality and its.
XSLT: How Do We Use It? Nancy Hallberg Nikki Massaro Kauffman.
ACG 4401 XSLT Extensible Stylesheet Language for Transformations Presenting XML and XBRL.
CITA 330 Section 5 XPath. XSL XSL (Extensible Stylesheet Language) is the standard language for writing stylesheets to transform XML documents among different.
Displaying Data with XSLT ©NIITeXtensible Markup Language/Lesson 6/Slide 1 of 45 Objectives In this lesson, you will learn to: * Perform conditional formatting.
5 Copyright © 2004, Oracle. All rights reserved. Navigating XML Documents by Using XPath.
XML Schema – XSLT Week 8 Web site:
Rendering XML Documents ©NIITeXtensible Markup Language/Lesson 5/Slide 1 of 46 Objectives In this session, you will learn to: * Define rendering * Identify.
CH 15 XSL Transformations 1. Objective What is XSL? Overview of XSL transformations Understanding XSL templates Computing the value of a node with xsl:value-of.
Unit 4 Representing Web Data: XML
Beginning XML 4th Edition.
In this session, you will learn to:
Xpath creation.
Tutorial 04 (cont’) Using XPath Patterns in an XSLT Style Sheet.
ACG 4401 XSLT Extensible Stylesheet Language for Transformations
XML Path Language Andy Clark 17 Apr 2002.
XML WITH CSS.
Murach's JavaScript and jQuery (3rd Ed.)
Presentation transcript:

#RefreshCache Effective XSLT Making use of XSLT to better customize your data. Daniel Hazelbaker Information Technology Manager High Desert Church

What is XSLT? XSLT is used to transform an XML document into another XML document, or another type of document that is recognized by a browser, like HTML. XSLT uses XPath to reference the elements inside the XML document.

Common Element Functions

Full Element Function List

XSLT/XPath Basics “group” – All node elements whose name is “group” – The “name” attribute of the current node = 1]” – All node elements whose name is “group” and has an attribute called “active” whose value is 1.

XSLT/XPath Basics (cont.) “group/member” – All node elements whose name is “member” and whose parent node name is “group” (that is, all group members). = = ‘Daniel’]” – All small group members whose first name is “Daniel” and is a member of a currently active group. = 1 and ‘Victorville’)]” – All small groups which are active and whose name contains the word “Victorville”

Using ‘if’ statements

Using ‘choose’ statements

Using Parameters no <![CDATA[... ]]>

Looping through a list More Info

Embedding Javascript or CSS <![CDATA[ $(document).ready(function() { alert('Document is ready!'); }); ]]>

Comparison Operators andLogical-and (&&) author[degree and award] orLogical-or (||) author[degree or award] =Equality = ‘yes’ !=Not equal != ‘yes’

Comparison Operators (cont.) <Less than (<) < 20] <=Less than or equal (<=) <= 400] >Greater than (>) > 20] >=Greater than or equal (>=) >= 400]

XPath Functions count() id() last() local-name() name() namespace-uri() position() concat() contains() normalize-space() starts-with() string() string-length() substring() substring-after() substring-before() translate() boolean() false() lang() not() true() ceiling() floor() number() round() sum()

Counting Tiny Small Groups There are small groups with less than 6 members.

Debugging for-each loops Processing element number of...

Cheat Sheets – XPath by DeepX Ltd – XSLT 1.0 Quick Reference by DeepX Ltd