SlideShare a Scribd company logo
Q5M1 - XML Dudy Fathan Ali S.Kom
Displaying Data with XSLT
Q5M1 - XML
Dudy Fathan Ali, S.Kom (DFA)
2015
CEP - CCIT
Fakultas Teknik Universitas Indonesia
Performing Conditional Formatting
Q5M1 - XML Dudy Fathan Ali S.Kom
Conditional formatting refers to the formatting of data based on a
specific condition.
The two elements used for conditional formatting are:
if
choose
Performing Conditional Formatting
Q5M1 - XML Dudy Fathan Ali S.Kom
Conditional formatting refers to the formatting of data based on a
specific condition.
The two elements used for conditional formatting are:
if
choose
Provides an if-then construct.
Follows the syntax:
<xsl:if test="condition">
[actions to be performed if the
condition is true]
</xsl:if>
Performing Conditional Formatting
Q5M1 - XML Dudy Fathan Ali S.Kom
Conditional formatting refers to the formatting of data based on a
specific condition.
The two elements used for conditional formatting are:
if
choose
Enables you to choose from two or more
possible courses of action by testing multiple
conditions.
Follows the syntax:
<xsl:choose>
<xsl:when>
[action to be taken]
</xsl:when>
:
:
<xsl:otherwise>
[action to be taken]
</xsl:otherwise>
</xsl:choose>
Identifying Comparison and Boolean Operators
Q5M1 - XML Dudy Fathan Ali S.Kom
Used with the if and choose elements to narrow down the
formatting criteria.
The following table lists various comparison and Boolean
operators.
Operator Meaning Example
Equal to=
PRICE[. = 20]
PRODUCTNAME[. = ‘Mini Bus’]
!=
&lt;
and
&lt;=
&gt;=
or
&gt;
Not equal to
Less than
Less than or equal to
Greater than
Logical AND
Logical OR
Greater than or equal to
PRICE[. != 20]
PRODUCTNAME[. != ‘Barbie Doll’]
PRICE[. &lt; 20]
PRICE[. &gt; 20]
PRICE[. &lt;= 20]
PRICE[. &gt;= 20]
PRICE[. &gt 20 and . &lt; 30]
PRICE[. = 20 or . = 45]
PRICE[not(. = 30)]not Negation Operator
Using XPath
Q5M1 - XML Dudy Fathan Ali S.Kom
XPath:
Is used to search and retrieve information from an XML file.
Treats an XML document as a tree of interrelated branches and
nodes, as shown in the following figure.
PRODUCTDATA
PRODUCT
PRODUCTNAME DESCRIPTION PRICE QOHPRODID=“P001”
CATEGORY
=“TOY”
Mini Bus
This toy is for
children aged
4 and above
5475
Describing XPath Expressions
Q5M1 - XML Dudy Fathan Ali S.Kom
XPath expressions can be used to retrieve data based on specific
conditions.
XPath expressions identify the nodes in an XML document based
on their names and values.
The following table lists the operators that can be used to create
XPath expressions.
Operator/Special
Character
Example Description
/ /PRODUCTDATA Selects the immediate child elements of
PRODUCTDATA. If this operator occurs at the start
of the pattern, it indicates that the child elements
should be selected from the root node.
// //PRODUCTNAME Searches for the specified element at any node
level.
. .PRODUCTNAME Indicates the current context.
.. ../PRODUCTNAME Selects the PRODUCTNAME element, which exists
within the parent of the current element.
* * Selects all elements.
Describing XPath Expressions
Q5M1 - XML Dudy Fathan Ali S.Kom
Operator/Speci
al Character
Example Description
@ @PRODUCTID Used as a prefix for the attribute.
@* @* Selects all attributes.
: : Separates the namespace prefix from the
element or attribute name.
( ) (PRICE*QUANTITY) Used to group operations.
[ ] [@PRODUCTID='P00
1']
Applies a filter pattern.
+ num1 + num2 Returns the sum of two numbers.
- num1 - num2 Returns the difference of two numbers.
* num1 * num2 Returns the product of two numbers.
div num1 div num2 Returns the quotient of two numbers.
mod num1 mod num2 Returns the modulus, that is, the remainder of
integer division.
Identifying Comparison and Boolean Operators
Q5M1 - XML Dudy Fathan Ali S.Kom
Save as : Latihan10.xml
Identifying Comparison and Boolean Operators
Q5M1 - XML Dudy Fathan Ali S.Kom
Save as : Latihan10.xsl
Q5M1 - XML Dudy Fathan Ali S.Kom
Thank You!
Dudy Fathan Ali S.Kom
dudy.fathan@eng.ui.ac.id
Ad

More Related Content

What's hot (19)

Introduction to XML
Introduction to XMLIntroduction to XML
Introduction to XML
Prabu U
 
Dtd
DtdDtd
Dtd
Manish Chaurasia
 
Xml basics
Xml basicsXml basics
Xml basics
Kumar
 
Xml basics for beginning
Xml basics for beginningXml basics for beginning
Xml basics for beginning
Ahmad Awsaf-uz-zaman
 
XML
XMLXML
XML
Osama Qunoo
 
XML, DTD & XSD Overview
XML, DTD & XSD OverviewXML, DTD & XSD Overview
XML, DTD & XSD Overview
Pradeep Rapolu
 
02 xml schema
02 xml schema02 xml schema
02 xml schema
Baskarkncet
 
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xml
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xmlXml theory 2005_[ngohaianh.info]_1_introduction-to-xml
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xml
Ông Thông
 
XML Presentation-2
XML Presentation-2XML Presentation-2
XML Presentation-2
Sudharsan S
 
XML
XMLXML
XML
Prabu U
 
Xml schema
Xml schemaXml schema
Xml schema
Akshaya Akshaya
 
Xml Presentation-3
Xml Presentation-3Xml Presentation-3
Xml Presentation-3
Sudharsan S
 
Basics of XML
Basics of XMLBasics of XML
Basics of XML
indiangarg
 
Xml Presentation-1
Xml Presentation-1Xml Presentation-1
Xml Presentation-1
Sudharsan S
 
Xml presentation
Xml presentationXml presentation
Xml presentation
Miguel Angel Teheran Garcia
 
00 introduction
00 introduction00 introduction
00 introduction
Baskarkncet
 
DTD
DTDDTD
DTD
Kumar
 
uptu web technology unit 2 Xml2
uptu web technology unit 2 Xml2uptu web technology unit 2 Xml2
uptu web technology unit 2 Xml2
Abhishek Kesharwani
 
03 x files
03 x files03 x files
03 x files
Baskarkncet
 

Viewers also liked (20)

4 xslt
4   xslt4   xslt
4 xslt
gauravashq
 
Unleashing the Power of XSLT: Catalog Records in Batch
Unleashing the Power of XSLT: Catalog Records in BatchUnleashing the Power of XSLT: Catalog Records in Batch
Unleashing the Power of XSLT: Catalog Records in Batch
c7002593
 
Web Services
Web ServicesWeb Services
Web Services
Gaurav Tyagi
 
The Mystical Principles of XSLT: Enlightenment through Software Visualization
The Mystical Principles of XSLT: Enlightenment through Software VisualizationThe Mystical Principles of XSLT: Enlightenment through Software Visualization
The Mystical Principles of XSLT: Enlightenment through Software Visualization
evanlenz
 
Applying an IBM SOA Approach to Manual Processes Automation
Applying an IBM SOA Approach to Manual Processes AutomationApplying an IBM SOA Approach to Manual Processes Automation
Applying an IBM SOA Approach to Manual Processes Automation
Prolifics
 
Xml part4
Xml part4Xml part4
Xml part4
NOHA AW
 
Xml part5
Xml part5Xml part5
Xml part5
NOHA AW
 
Interoperable Web Services with JAX-WS
Interoperable Web Services with JAX-WSInteroperable Web Services with JAX-WS
Interoperable Web Services with JAX-WS
Carol McDonald
 
SOA Governance and WebSphere Service Registry and Repository
SOA Governance and WebSphere Service Registry and RepositorySOA Governance and WebSphere Service Registry and Repository
SOA Governance and WebSphere Service Registry and Repository
IBM Sverige
 
Open Id, O Auth And Webservices
Open Id, O Auth And WebservicesOpen Id, O Auth And Webservices
Open Id, O Auth And Webservices
Myles Eftos
 
XSLT for Web Developers
XSLT for Web DevelopersXSLT for Web Developers
XSLT for Web Developers
Sanders Kleinfeld
 
Web Services
Web ServicesWeb Services
Web Services
Gaurav Tyagi
 
Web services
Web servicesWeb services
Web services
Michael Weiss
 
WebService-Java
WebService-JavaWebService-Java
WebService-Java
halwal
 
Siebel Web Service
Siebel Web ServiceSiebel Web Service
Siebel Web Service
NAVINKUMAR RAI
 
CTDA Workshop on XSL
CTDA Workshop on XSLCTDA Workshop on XSL
CTDA Workshop on XSL
University of Connecticut Libraries
 
RESTful services
RESTful servicesRESTful services
RESTful services
gouthamrv
 
Java web services using JAX-WS
Java web services using JAX-WSJava web services using JAX-WS
Java web services using JAX-WS
IndicThreads
 
XSLT
XSLTXSLT
XSLT
rpoplai
 
OAuth 2.0 with IBM WebSphere DataPower
OAuth 2.0 with IBM WebSphere DataPowerOAuth 2.0 with IBM WebSphere DataPower
OAuth 2.0 with IBM WebSphere DataPower
Shiu-Fun Poon
 
Unleashing the Power of XSLT: Catalog Records in Batch
Unleashing the Power of XSLT: Catalog Records in BatchUnleashing the Power of XSLT: Catalog Records in Batch
Unleashing the Power of XSLT: Catalog Records in Batch
c7002593
 
The Mystical Principles of XSLT: Enlightenment through Software Visualization
The Mystical Principles of XSLT: Enlightenment through Software VisualizationThe Mystical Principles of XSLT: Enlightenment through Software Visualization
The Mystical Principles of XSLT: Enlightenment through Software Visualization
evanlenz
 
Applying an IBM SOA Approach to Manual Processes Automation
Applying an IBM SOA Approach to Manual Processes AutomationApplying an IBM SOA Approach to Manual Processes Automation
Applying an IBM SOA Approach to Manual Processes Automation
Prolifics
 
Xml part4
Xml part4Xml part4
Xml part4
NOHA AW
 
Xml part5
Xml part5Xml part5
Xml part5
NOHA AW
 
Interoperable Web Services with JAX-WS
Interoperable Web Services with JAX-WSInteroperable Web Services with JAX-WS
Interoperable Web Services with JAX-WS
Carol McDonald
 
SOA Governance and WebSphere Service Registry and Repository
SOA Governance and WebSphere Service Registry and RepositorySOA Governance and WebSphere Service Registry and Repository
SOA Governance and WebSphere Service Registry and Repository
IBM Sverige
 
Open Id, O Auth And Webservices
Open Id, O Auth And WebservicesOpen Id, O Auth And Webservices
Open Id, O Auth And Webservices
Myles Eftos
 
WebService-Java
WebService-JavaWebService-Java
WebService-Java
halwal
 
RESTful services
RESTful servicesRESTful services
RESTful services
gouthamrv
 
Java web services using JAX-WS
Java web services using JAX-WSJava web services using JAX-WS
Java web services using JAX-WS
IndicThreads
 
OAuth 2.0 with IBM WebSphere DataPower
OAuth 2.0 with IBM WebSphere DataPowerOAuth 2.0 with IBM WebSphere DataPower
OAuth 2.0 with IBM WebSphere DataPower
Shiu-Fun Poon
 
Ad

Similar to XML - Displaying Data ith XSLT (20)

Xml session07
Xml session07Xml session07
Xml session07
Niit Care
 
03 sm3 xml_xp_06
03 sm3 xml_xp_0603 sm3 xml_xp_06
03 sm3 xml_xp_06
Niit Care
 
Session 4
Session 4Session 4
Session 4
Lại Đức Chung
 
Rendering XML Document
Rendering XML DocumentRendering XML Document
Rendering XML Document
yht4ever
 
Xslt by asfak mahamud
Xslt by asfak mahamudXslt by asfak mahamud
Xslt by asfak mahamud
Asfak Mahamud
 
Day2 xslt x_path_xquery
Day2 xslt x_path_xqueryDay2 xslt x_path_xquery
Day2 xslt x_path_xquery
XAVIERCONSULTANTS
 
Xml session
Xml sessionXml session
Xml session
Farag Zakaria
 
Stax parser
Stax parserStax parser
Stax parser
ShanmukhaChariK
 
Xml and DTD's
Xml and DTD'sXml and DTD's
Xml and DTD's
Swati Parmar
 
programming with xml for graduate students
programming with xml for graduate studentsprogramming with xml for graduate students
programming with xml for graduate students
RameshPrasadBhatta2
 
(151030) The X files
(151030) The X files(151030) The X files
(151030) The X files
Paul Filkin
 
An Architecture for an XML-Template Engine enabling Safe Authoring
An Architecture for an XML-Template Engine enabling Safe AuthoringAn Architecture for an XML-Template Engine enabling Safe Authoring
An Architecture for an XML-Template Engine enabling Safe Authoring
Falk Hartmann
 
Rendering XML Documents
Rendering XML DocumentsRendering XML Documents
Rendering XML Documents
yht4ever
 
Xml Session No 1
Xml Session No 1Xml Session No 1
Xml Session No 1
Saif Ullah Dar
 
Creating xml publisher documents with people code
Creating xml publisher documents with people codeCreating xml publisher documents with people code
Creating xml publisher documents with people code
Randall Groncki
 
Integrative Programming and Technology Chapter 4- Dr. J. VijiPriya
Integrative Programming and Technology Chapter 4- Dr. J. VijiPriyaIntegrative Programming and Technology Chapter 4- Dr. J. VijiPriya
Integrative Programming and Technology Chapter 4- Dr. J. VijiPriya
VijiPriya Jeyamani
 
treeview
treeviewtreeview
treeview
tutorialsruby
 
treeview
treeviewtreeview
treeview
tutorialsruby
 
XPath Injection
XPath InjectionXPath Injection
XPath Injection
Roberto Suggi Liverani
 
Unit2_XML_S_SS_US Data_CS19414.pptx
Unit2_XML_S_SS_US Data_CS19414.pptxUnit2_XML_S_SS_US Data_CS19414.pptx
Unit2_XML_S_SS_US Data_CS19414.pptx
NEHARAJPUT239591
 
Xml session07
Xml session07Xml session07
Xml session07
Niit Care
 
03 sm3 xml_xp_06
03 sm3 xml_xp_0603 sm3 xml_xp_06
03 sm3 xml_xp_06
Niit Care
 
Rendering XML Document
Rendering XML DocumentRendering XML Document
Rendering XML Document
yht4ever
 
Xslt by asfak mahamud
Xslt by asfak mahamudXslt by asfak mahamud
Xslt by asfak mahamud
Asfak Mahamud
 
programming with xml for graduate students
programming with xml for graduate studentsprogramming with xml for graduate students
programming with xml for graduate students
RameshPrasadBhatta2
 
(151030) The X files
(151030) The X files(151030) The X files
(151030) The X files
Paul Filkin
 
An Architecture for an XML-Template Engine enabling Safe Authoring
An Architecture for an XML-Template Engine enabling Safe AuthoringAn Architecture for an XML-Template Engine enabling Safe Authoring
An Architecture for an XML-Template Engine enabling Safe Authoring
Falk Hartmann
 
Rendering XML Documents
Rendering XML DocumentsRendering XML Documents
Rendering XML Documents
yht4ever
 
Creating xml publisher documents with people code
Creating xml publisher documents with people codeCreating xml publisher documents with people code
Creating xml publisher documents with people code
Randall Groncki
 
Integrative Programming and Technology Chapter 4- Dr. J. VijiPriya
Integrative Programming and Technology Chapter 4- Dr. J. VijiPriyaIntegrative Programming and Technology Chapter 4- Dr. J. VijiPriya
Integrative Programming and Technology Chapter 4- Dr. J. VijiPriya
VijiPriya Jeyamani
 
Unit2_XML_S_SS_US Data_CS19414.pptx
Unit2_XML_S_SS_US Data_CS19414.pptxUnit2_XML_S_SS_US Data_CS19414.pptx
Unit2_XML_S_SS_US Data_CS19414.pptx
NEHARAJPUT239591
 
Ad

More from Dudy Ali (20)

Understanding COM+
Understanding COM+Understanding COM+
Understanding COM+
Dudy Ali
 
Distributed Application Development (Introduction)
Distributed Application Development (Introduction)Distributed Application Development (Introduction)
Distributed Application Development (Introduction)
Dudy Ali
 
Java CRUD Mechanism with SQL Server Database
Java CRUD Mechanism with SQL Server DatabaseJava CRUD Mechanism with SQL Server Database
Java CRUD Mechanism with SQL Server Database
Dudy Ali
 
Network Socket Programming with JAVA
Network Socket Programming with JAVANetwork Socket Programming with JAVA
Network Socket Programming with JAVA
Dudy Ali
 
Review Materi ASP.NET
Review Materi ASP.NETReview Materi ASP.NET
Review Materi ASP.NET
Dudy Ali
 
Pengantar XML
Pengantar XMLPengantar XML
Pengantar XML
Dudy Ali
 
Pengantar XML DOM
Pengantar XML DOMPengantar XML DOM
Pengantar XML DOM
Dudy Ali
 
Pengantar ADO.NET
Pengantar ADO.NETPengantar ADO.NET
Pengantar ADO.NET
Dudy Ali
 
Database Connectivity with JDBC
Database Connectivity with JDBCDatabase Connectivity with JDBC
Database Connectivity with JDBC
Dudy Ali
 
Algorithm & Data Structure - Algoritma Pengurutan
Algorithm & Data Structure - Algoritma PengurutanAlgorithm & Data Structure - Algoritma Pengurutan
Algorithm & Data Structure - Algoritma Pengurutan
Dudy Ali
 
Algorithm & Data Structure - Pengantar
Algorithm & Data Structure - PengantarAlgorithm & Data Structure - Pengantar
Algorithm & Data Structure - Pengantar
Dudy Ali
 
Object Oriented Programming - Value Types & Reference Types
Object Oriented Programming - Value Types & Reference TypesObject Oriented Programming - Value Types & Reference Types
Object Oriented Programming - Value Types & Reference Types
Dudy Ali
 
Object Oriented Programming - Inheritance
Object Oriented Programming - InheritanceObject Oriented Programming - Inheritance
Object Oriented Programming - Inheritance
Dudy Ali
 
Object Oriented Programming - File Input & Output
Object Oriented Programming - File Input & OutputObject Oriented Programming - File Input & Output
Object Oriented Programming - File Input & Output
Dudy Ali
 
Object Oriented Programming - Constructors & Destructors
Object Oriented Programming - Constructors & DestructorsObject Oriented Programming - Constructors & Destructors
Object Oriented Programming - Constructors & Destructors
Dudy Ali
 
Object Oriented Programming - Abstraction & Encapsulation
Object Oriented Programming - Abstraction & EncapsulationObject Oriented Programming - Abstraction & Encapsulation
Object Oriented Programming - Abstraction & Encapsulation
Dudy Ali
 
Web Programming Syaria - Pengenalan Halaman Web
Web Programming Syaria - Pengenalan Halaman WebWeb Programming Syaria - Pengenalan Halaman Web
Web Programming Syaria - Pengenalan Halaman Web
Dudy Ali
 
Web Programming Syaria - PHP
Web Programming Syaria - PHPWeb Programming Syaria - PHP
Web Programming Syaria - PHP
Dudy Ali
 
Software Project Management - Project Management Knowledge
Software Project Management - Project Management KnowledgeSoftware Project Management - Project Management Knowledge
Software Project Management - Project Management Knowledge
Dudy Ali
 
Software Project Management - Proses Manajemen Proyek
Software Project Management - Proses Manajemen ProyekSoftware Project Management - Proses Manajemen Proyek
Software Project Management - Proses Manajemen Proyek
Dudy Ali
 
Understanding COM+
Understanding COM+Understanding COM+
Understanding COM+
Dudy Ali
 
Distributed Application Development (Introduction)
Distributed Application Development (Introduction)Distributed Application Development (Introduction)
Distributed Application Development (Introduction)
Dudy Ali
 
Java CRUD Mechanism with SQL Server Database
Java CRUD Mechanism with SQL Server DatabaseJava CRUD Mechanism with SQL Server Database
Java CRUD Mechanism with SQL Server Database
Dudy Ali
 
Network Socket Programming with JAVA
Network Socket Programming with JAVANetwork Socket Programming with JAVA
Network Socket Programming with JAVA
Dudy Ali
 
Review Materi ASP.NET
Review Materi ASP.NETReview Materi ASP.NET
Review Materi ASP.NET
Dudy Ali
 
Pengantar XML
Pengantar XMLPengantar XML
Pengantar XML
Dudy Ali
 
Pengantar XML DOM
Pengantar XML DOMPengantar XML DOM
Pengantar XML DOM
Dudy Ali
 
Pengantar ADO.NET
Pengantar ADO.NETPengantar ADO.NET
Pengantar ADO.NET
Dudy Ali
 
Database Connectivity with JDBC
Database Connectivity with JDBCDatabase Connectivity with JDBC
Database Connectivity with JDBC
Dudy Ali
 
Algorithm & Data Structure - Algoritma Pengurutan
Algorithm & Data Structure - Algoritma PengurutanAlgorithm & Data Structure - Algoritma Pengurutan
Algorithm & Data Structure - Algoritma Pengurutan
Dudy Ali
 
Algorithm & Data Structure - Pengantar
Algorithm & Data Structure - PengantarAlgorithm & Data Structure - Pengantar
Algorithm & Data Structure - Pengantar
Dudy Ali
 
Object Oriented Programming - Value Types & Reference Types
Object Oriented Programming - Value Types & Reference TypesObject Oriented Programming - Value Types & Reference Types
Object Oriented Programming - Value Types & Reference Types
Dudy Ali
 
Object Oriented Programming - Inheritance
Object Oriented Programming - InheritanceObject Oriented Programming - Inheritance
Object Oriented Programming - Inheritance
Dudy Ali
 
Object Oriented Programming - File Input & Output
Object Oriented Programming - File Input & OutputObject Oriented Programming - File Input & Output
Object Oriented Programming - File Input & Output
Dudy Ali
 
Object Oriented Programming - Constructors & Destructors
Object Oriented Programming - Constructors & DestructorsObject Oriented Programming - Constructors & Destructors
Object Oriented Programming - Constructors & Destructors
Dudy Ali
 
Object Oriented Programming - Abstraction & Encapsulation
Object Oriented Programming - Abstraction & EncapsulationObject Oriented Programming - Abstraction & Encapsulation
Object Oriented Programming - Abstraction & Encapsulation
Dudy Ali
 
Web Programming Syaria - Pengenalan Halaman Web
Web Programming Syaria - Pengenalan Halaman WebWeb Programming Syaria - Pengenalan Halaman Web
Web Programming Syaria - Pengenalan Halaman Web
Dudy Ali
 
Web Programming Syaria - PHP
Web Programming Syaria - PHPWeb Programming Syaria - PHP
Web Programming Syaria - PHP
Dudy Ali
 
Software Project Management - Project Management Knowledge
Software Project Management - Project Management KnowledgeSoftware Project Management - Project Management Knowledge
Software Project Management - Project Management Knowledge
Dudy Ali
 
Software Project Management - Proses Manajemen Proyek
Software Project Management - Proses Manajemen ProyekSoftware Project Management - Proses Manajemen Proyek
Software Project Management - Proses Manajemen Proyek
Dudy Ali
 

Recently uploaded (20)

Designing Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep Dive
Designing Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep DiveDesigning Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep Dive
Designing Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep Dive
ScyllaDB
 
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-UmgebungenHCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
panagenda
 
Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025
Splunk
 
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
Alan Dix
 
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Impelsys Inc.
 
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
BookNet Canada
 
TrsLabs - Fintech Product & Business Consulting
TrsLabs - Fintech Product & Business ConsultingTrsLabs - Fintech Product & Business Consulting
TrsLabs - Fintech Product & Business Consulting
Trs Labs
 
AI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global TrendsAI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global Trends
InData Labs
 
Linux Professional Institute LPIC-1 Exam.pdf
Linux Professional Institute LPIC-1 Exam.pdfLinux Professional Institute LPIC-1 Exam.pdf
Linux Professional Institute LPIC-1 Exam.pdf
RHCSA Guru
 
2025-05-Q4-2024-Investor-Presentation.pptx
2025-05-Q4-2024-Investor-Presentation.pptx2025-05-Q4-2024-Investor-Presentation.pptx
2025-05-Q4-2024-Investor-Presentation.pptx
Samuele Fogagnolo
 
HCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser EnvironmentsHCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser Environments
panagenda
 
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxDevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
Justin Reock
 
Drupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy ConsumptionDrupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy Consumption
Exove
 
Generative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in BusinessGenerative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in Business
Dr. Tathagat Varma
 
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfThe Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
Abi john
 
Technology Trends in 2025: AI and Big Data Analytics
Technology Trends in 2025: AI and Big Data AnalyticsTechnology Trends in 2025: AI and Big Data Analytics
Technology Trends in 2025: AI and Big Data Analytics
InData Labs
 
Big Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur MorganBig Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur Morgan
Arthur Morgan
 
How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?
Daniel Lehner
 
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdfComplete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Software Company
 
Cybersecurity Identity and Access Solutions using Azure AD
Cybersecurity Identity and Access Solutions using Azure ADCybersecurity Identity and Access Solutions using Azure AD
Cybersecurity Identity and Access Solutions using Azure AD
VICTOR MAESTRE RAMIREZ
 
Designing Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep Dive
Designing Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep DiveDesigning Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep Dive
Designing Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep Dive
ScyllaDB
 
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-UmgebungenHCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
panagenda
 
Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025
Splunk
 
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
Alan Dix
 
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Impelsys Inc.
 
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
BookNet Canada
 
TrsLabs - Fintech Product & Business Consulting
TrsLabs - Fintech Product & Business ConsultingTrsLabs - Fintech Product & Business Consulting
TrsLabs - Fintech Product & Business Consulting
Trs Labs
 
AI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global TrendsAI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global Trends
InData Labs
 
Linux Professional Institute LPIC-1 Exam.pdf
Linux Professional Institute LPIC-1 Exam.pdfLinux Professional Institute LPIC-1 Exam.pdf
Linux Professional Institute LPIC-1 Exam.pdf
RHCSA Guru
 
2025-05-Q4-2024-Investor-Presentation.pptx
2025-05-Q4-2024-Investor-Presentation.pptx2025-05-Q4-2024-Investor-Presentation.pptx
2025-05-Q4-2024-Investor-Presentation.pptx
Samuele Fogagnolo
 
HCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser EnvironmentsHCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser Environments
panagenda
 
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxDevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
Justin Reock
 
Drupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy ConsumptionDrupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy Consumption
Exove
 
Generative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in BusinessGenerative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in Business
Dr. Tathagat Varma
 
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfThe Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
Abi john
 
Technology Trends in 2025: AI and Big Data Analytics
Technology Trends in 2025: AI and Big Data AnalyticsTechnology Trends in 2025: AI and Big Data Analytics
Technology Trends in 2025: AI and Big Data Analytics
InData Labs
 
Big Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur MorganBig Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur Morgan
Arthur Morgan
 
How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?
Daniel Lehner
 
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdfComplete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Software Company
 
Cybersecurity Identity and Access Solutions using Azure AD
Cybersecurity Identity and Access Solutions using Azure ADCybersecurity Identity and Access Solutions using Azure AD
Cybersecurity Identity and Access Solutions using Azure AD
VICTOR MAESTRE RAMIREZ
 

XML - Displaying Data ith XSLT

  • 1. Q5M1 - XML Dudy Fathan Ali S.Kom Displaying Data with XSLT Q5M1 - XML Dudy Fathan Ali, S.Kom (DFA) 2015 CEP - CCIT Fakultas Teknik Universitas Indonesia
  • 2. Performing Conditional Formatting Q5M1 - XML Dudy Fathan Ali S.Kom Conditional formatting refers to the formatting of data based on a specific condition. The two elements used for conditional formatting are: if choose
  • 3. Performing Conditional Formatting Q5M1 - XML Dudy Fathan Ali S.Kom Conditional formatting refers to the formatting of data based on a specific condition. The two elements used for conditional formatting are: if choose Provides an if-then construct. Follows the syntax: <xsl:if test="condition"> [actions to be performed if the condition is true] </xsl:if>
  • 4. Performing Conditional Formatting Q5M1 - XML Dudy Fathan Ali S.Kom Conditional formatting refers to the formatting of data based on a specific condition. The two elements used for conditional formatting are: if choose Enables you to choose from two or more possible courses of action by testing multiple conditions. Follows the syntax: <xsl:choose> <xsl:when> [action to be taken] </xsl:when> : : <xsl:otherwise> [action to be taken] </xsl:otherwise> </xsl:choose>
  • 5. Identifying Comparison and Boolean Operators Q5M1 - XML Dudy Fathan Ali S.Kom Used with the if and choose elements to narrow down the formatting criteria. The following table lists various comparison and Boolean operators. Operator Meaning Example Equal to= PRICE[. = 20] PRODUCTNAME[. = ‘Mini Bus’] != &lt; and &lt;= &gt;= or &gt; Not equal to Less than Less than or equal to Greater than Logical AND Logical OR Greater than or equal to PRICE[. != 20] PRODUCTNAME[. != ‘Barbie Doll’] PRICE[. &lt; 20] PRICE[. &gt; 20] PRICE[. &lt;= 20] PRICE[. &gt;= 20] PRICE[. &gt 20 and . &lt; 30] PRICE[. = 20 or . = 45] PRICE[not(. = 30)]not Negation Operator
  • 6. Using XPath Q5M1 - XML Dudy Fathan Ali S.Kom XPath: Is used to search and retrieve information from an XML file. Treats an XML document as a tree of interrelated branches and nodes, as shown in the following figure. PRODUCTDATA PRODUCT PRODUCTNAME DESCRIPTION PRICE QOHPRODID=“P001” CATEGORY =“TOY” Mini Bus This toy is for children aged 4 and above 5475
  • 7. Describing XPath Expressions Q5M1 - XML Dudy Fathan Ali S.Kom XPath expressions can be used to retrieve data based on specific conditions. XPath expressions identify the nodes in an XML document based on their names and values. The following table lists the operators that can be used to create XPath expressions. Operator/Special Character Example Description / /PRODUCTDATA Selects the immediate child elements of PRODUCTDATA. If this operator occurs at the start of the pattern, it indicates that the child elements should be selected from the root node. // //PRODUCTNAME Searches for the specified element at any node level. . .PRODUCTNAME Indicates the current context. .. ../PRODUCTNAME Selects the PRODUCTNAME element, which exists within the parent of the current element. * * Selects all elements.
  • 8. Describing XPath Expressions Q5M1 - XML Dudy Fathan Ali S.Kom Operator/Speci al Character Example Description @ @PRODUCTID Used as a prefix for the attribute. @* @* Selects all attributes. : : Separates the namespace prefix from the element or attribute name. ( ) (PRICE*QUANTITY) Used to group operations. [ ] [@PRODUCTID='P00 1'] Applies a filter pattern. + num1 + num2 Returns the sum of two numbers. - num1 - num2 Returns the difference of two numbers. * num1 * num2 Returns the product of two numbers. div num1 div num2 Returns the quotient of two numbers. mod num1 mod num2 Returns the modulus, that is, the remainder of integer division.
  • 9. Identifying Comparison and Boolean Operators Q5M1 - XML Dudy Fathan Ali S.Kom Save as : Latihan10.xml
  • 10. Identifying Comparison and Boolean Operators Q5M1 - XML Dudy Fathan Ali S.Kom Save as : Latihan10.xsl
  • 11. Q5M1 - XML Dudy Fathan Ali S.Kom Thank You! Dudy Fathan Ali S.Kom [email protected]