Dynamic Content, Timers, XML




CS174

Chris Pollett

Nov 16, 2020

Outline

Moving Elements

Element Visibility, Colors and Fonts

Dynamic Content

Timers

Quiz

Which of the following statements is true?

  1. $ is a regex archor used to match the end of a string.
  2. Typically, one writes an onclick event handler for a form button if one wants to validate a form.
  3. HTML element properties cannot be altered by Javascript.

Introduction to XML

The Syntax of XML

XML Document Structure and Entities

Document Type Definitions

<!ELEMENT ..>

<!ATTLIST ..>

<!ENTITY ..>

Example DTD

<?xml version = "1.0" encoding ="utf-8" ?>
<!-- planes_for_sale.dtd  -->
<!ELEMENT planes_for_sale (ad+) >
<!ELEMENT ad (year, make, model, color, price?, seller) >
<!ELEMENT year (#PCDATA)>
<!ELEMENT make (#PCDATA)>
<!ELEMENT model (#PCDATA)>
<!ELEMENT color (#PCDATA)>
<!ELEMENT price (#PCDATA)>
<!ELEMENT seller (#PCDATA)>
<!ATTLIST seller license CDATA #REQUIRED >
<!ENTITY c "cessna" >

Internal versus External DTDs

Namespaces

XML and CSS