Using XML. The Ticket Booth System We need a way to retain information between program runs. In real life, we would probably use a database system for.

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

Copyright © 2003 Pearson Education, Inc. Slide 1-1 The Web Wizards Guide to PHP by David A. Lash.
WeB application development
Website Design.
ASHIMA KALRA.  WHAT IS HTML WHAT IS HTML  HTML TAGS HTML TAGS  FORMATTING TAGS FORMATTING TAGS.
SPECIAL TOPIC XML. Introducing XML XML (eXtensible Markup Language) ◦A language used to create structured documents XML vs HTML ◦XML is designed to transport.
ICS-FORTH 1 May 22, 2001 Christos Georgis The extensible markup language: An introduction to XML What is a XML document ? How do we check its validity.
XML Unit 6 October 31. XML, review XML is used to markup data Used to describe information Uses tags like HTML –But all tags are user-defined –Must be.
1 Extensible Markup Language: XML HTML: portable, widely supported protocol for describing how to format data XML: portable, widely supported protocol.
Made by: Dan Ye. Introduction Basic Last Page ☆ HTML stands for Hyper Text Markup Language; ☆ HTML is not a programming language, it is a markup language;
IS 373—Web Standards Todd Will
1 Extensible Markup Language: XML HTML: portable, widely supported protocol for describing how to format data XML: portable, widely supported protocol.
Sistemi basati su conoscenza XML Prof. M.T. PAZIENZA a.a
1 Web Wizards Guide To PHP David Lash Chapter 1 Introduction to PHP.
23-Jun-15 HTML. 2 Web pages are HTML HTML stands for HyperText Markup Language Web pages are plain text files, written in HTML Browsers display web pages.
Sistemi basati su conoscenza XML Prof. M.T. PAZIENZA a.a
XML Primer. 2 History: SGML vs. HTML vs. XML SGML (1960) XML(1996) HTML(1990) XHTML(2000)
Introduction to XML: Yong Choi CSU Bakersfield.
Introduction to XML Extensible Markup Language Carol Wolf Computer Science Department.
Introduction to XML Rashmi Kukanur. XML XML stands for Extensible Markup Language XML was designed to carry data XML and HTML designed with different.
Pemrograman Berbasis WEB XML part 2 -Aurelio Rahmadian- Sumber: w3cschools.com.
XML introduction to Ahmed I. Deeb Dr. Anwar Mousa  presenter  instructor University Of Palestine-2009.
 Introduction to XML Introduction to XML  Features of XML Features of XML  Syntax of XML Syntax of XML  Syntax rules of XML document Syntax rules.
DAT602 Database Application Development Lecture 14 HTML.
CREATED BY ChanoknanChinnanon PanissaraUsanachote
1Computer Sciences Department Princess Nourah bint Abdulrahman University.
HTML Structure & syntax
HTML INTRODUCTION, EDITORS, BASIC, ELEMENTS, ATTRIBUTES.
HTML. WHAT IS HTML HTML stands for Hyper Text Markup Language HTML is not a programming language, it is a markup language A markup language is a set of.
HTML CRASH COURSE. What is HTML?  Hyper Text Markup Language  The language used to make web pages  Written by using tags.
What is XML?  XML stands for EXtensible Markup Language  XML is a markup language much like HTML  XML was designed to carry data, not to display data.
These Questions are copied from
Introduction to HTML. What is a HTML File?  HTML stands for Hyper Text Markup Language  An HTML file is a text file containing small markup tags  The.
Introduction to XML Extensible Markup Language. What is XML XML stands for eXtensible Markup Language. A markup language is used to provide information.
 XML is designed to describe data and to focus on what data is. HTML is designed to display data and to focus on how data looks.  XML is created to structure,
Introduction to HTML. What is HTML? Hyper Text Markup Language (HTML) is a language for describing web pages. HTML is not a programming language, it is.
HTML INTRODUCTION. What is HTML?  HTML stands for Hypertext Markup Language  Developed in 1990  Hidden code that helps us communicate with others on.
Basic HTML PowerPoint How Hyper Text Markup Language Works
How do I use HTML and XML to present information?.
XML eXtensible Markup Language. Topics  What is XML  An XML example  Why is XML important  XML introduction  XML applications  XML support CSEB.
Softsmith Infotech XML. Softsmith Infotech XML EXtensible Markup Language XML is a markup language much like HTML Designed to carry data, not to display.
Introduction to HTML Wah Yan College (Hong Kong) Mr. Li C.P.
1 Using XML. 2 The Ticket Booth System We need a way to retain information between program runs. In real life, we would probably use a database system.
HTML Structure & syntax. Introduction This presentation introduces the following: Doctype declaration HTML Tags, Elements and Attributes Sections of a.
HTML Basics Let’s Make a Web Page. What is HTML? HTML is a language for describing web pages. HTML stands for Hyper Text Markup Language HTML is not a.
Introduction to XML This presentation covers introductory features of XML. What XML is and what it is not? What does it do? Put different related technologies.
1 Credits Prepared by: Rajendra P. Srivastava Ernst & Young Professor University of Kansas Sponsored by: Ernst & Young, LLP (August 2005) XBRL Module Part.
McGraw-Hill/Irwin © 2004 by The McGraw-Hill Companies, Inc. All rights reserved. Understanding How XML Works Ellen Pearlman Eileen Mullin Programming the.
XML Introduction. What is XML? XML stands for eXtensible Markup Language XML stands for eXtensible Markup Language XML is a markup language much like.
What it is and how it works
Lecture: Web Design Assis. Prof. Freshta Hanif Ehsan Faculty of Computer Science Kabul Polytechnic University Spring Semester
XML Basics A brief introduction to XML in general 1XML Basics.
Kevin Murphy Basics of XML Masters Project CS 490.
Jennifer Widom XML Data Introduction, Well-formed XML.
Ticket Booth Base Level 3 1. In the completed program, the ticket seller will: Select a venue from a menu of all venues. Select a show from a menu of.
Introduction to HTML Year 8. What is HTML O Hyper Text Mark-up Language O The language that all the elements of a web page are written in. O It describes.
Well Formed XML The basics. A Simple XML Document Smith Alice.
ASHIMA KALRA  INTRODUCTION OF XML INTRODUCTION OF XML  XML FEATURES XML FEATURES  XML SYNTAX XML SYNTAX  XML ELEMENTS XML ELEMENTS  XML ATTRIBUTES.
WEEK -1 ACM 262 ACM 262 Course Notes. HTML What is HTML? HTML is a language for describing web pages. HTML stands for Hyper Text Markup Language HTML.
XML. HTML Before you continue you should have a basic understanding of the following: HTML HTML was designed to display data and to focus on how data.
VCE IT Theory Slideshows by Mark Kelly study design By Mark Kelly, vceit.com, Begin.
XML Notes taken from w3schools. What is XML? XML stands for EXtensible Markup Language. XML was designed to store and transport data. XML was designed.
NOTEPAD++ Lab 1 1 Riham ALSmari. Why Notepad++ ?  Syntax highlighting  Tabbed document interface  Zooming  Indentation code  Find and replace over.
HTML Structure & syntax
Pertemuan 1 Desain web Pertemuan 1
XML Data Introduction, Well-formed XML.
Javascript & jQuery XML.
Internet Technologies I - Lect.01 - Waleed Ibrahim Osman
14 XML.
HTML Structure & syntax
Presentation transcript:

Using XML

The Ticket Booth System We need a way to retain information between program runs. In real life, we would probably use a database system for this. Beyond the scope of this course. We will use text files.

XML Extensible Markup Language A metalanguage Language used to describe languages Using XML we can create a markup language for a specific purpose. Self describing. Text based System independent

XML Like C++, XML is a big subject. Just a brief introduction in this course. But enough to do useful work.

The Little Theater Row A Row B Row C Row D Row E Row F Front Section Back Section Left Section Right Section Center Section

Example: Venue.xml Download: Downloads/2016_03_01_XML/Venue.xml Downloads/2016_03_01_XML/Venue.xml Open in Visual Studio Or you can view the file in any browser.

Venue.xml in Visual Studio

Things to Notice First line Every xml file begins like this. The words in angle brackets are tags. Tags always come in matched pairs:... Every well formed xml file has a single root tag. in this case. Tags must be properly nested.

Things to Notice Everything between a start tag and its matching end tag is information about an object identified by the start tag. Similar concept to objects in OOP. In Visual Studio, and other xml aware editors, we can collapse or expand the tags. There can be multiple instances of a tag name....

XML Tag Names Tag names are similar to variable names in C++. Tag names are case sensitive. Cannot contain spaces, punctuation, etc. Letters, digits, and the underscore character. First character cannot be a digit.

Comments XML files can include comments Same as HTML Comments can extend over multiple lines.

Seat Row

Describing a Seat Row A seat_row has: A Name An arbitrary number of Seats. Each seat has A number A section name

Using XML in a Program We can write code to output objects to an XML file. Similar to a Display method. Save objects on disk between program runs. Serialization. Likewise, we can create objects using information read from an XML file. Deserialization Need an XML parser.

Other XML Files _03_01_XML/Venue.xml Ticket.xml Show.xml Booking.xml

A Ticket in XML

A Show in XML

A Booking in XML

Booking (continued)

Exercise What will be the price of a ticket for seat B4 for the performance of the Music Man at the Little Theater on Dec. 2, 2010? Try to answer this on your own, before looking at the answer on the next slide.

Answer $95 Venue Seat B4 is in the Center section. Booking The Center section will have price level 1 Dec. 2 will have the Normal price schedule. Show In the Normal price schedule, level 1 is $95