Teaching HTML and CSS [#2]
The vastness of the internet leaves a lot to imagine what exactly content sits inside in order to be visible. After thinking about how to go about teaching how and what it takes to create websites, I realized that I need to do what I do best. I have to explain how to do things and why it works in my own way in order to keep things interesting. I am not a programmer (see my About page for more info on me) so this experiment isn’t going to be your typical html class.
Its called the Document Object Model, or DOM, and is what one needs to be aware of when creating content in any type page. It is the official “standard for representing structured documents in a platform and language neutral manner,” w3c.org .
Eh, yeah, so now that you know exactly what it “is”, lets discuss what it … is.
The space in which you organize your information in order for things to receive information, and do whatever you tell it to do. I view it as one piece of blackness in the vastness of the internet universe. Being that there are multiple types of html pages (versions and compatibilities), the doctype defines the page in a “machine-readable language specifying the information of a type of HTML”. You must set the doctype in order for your page to be viewed and function properly.
These are the ones we need to know;
HTML 4.01 Strict, Transitional, Frameset
<!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01//EN”
“http://www.w3.org/TR/html4/strict.dtd”><!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN”
“http://www.w3.org/TR/html4/loose.dtd”><!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01 Frameset//EN”
“http://www.w3.org/TR/html4/frameset.dtd”>XHTML 1.0 Strict, Transitional, Frameset
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN”
“http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd”><!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN”
“http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”><!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Frameset//EN”
“http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd”>XHTML 1.1 DTD
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.1//EN”
“http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd”>
The one that we will be using is this:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
It will comply with all major web browsers and allow us to write what we need. This snippet will go at the extreme top of the page, first thing with nothing else.