All posts tagged ‘HTML’

File Under: HTML, Web Standards

Building with the Document Object Model

How would you describe your web page without mentioning its content?

One way would be to describe the page’s structure. What tags are on the page? How many are there? What order are they in? What are the properties of these tags? And finally, what is the presentational nature of each element? This is what the Document Object Model does. It expresses the structure of an HTML document in a universal, content-neutral way.

One of my first Webmonkey articles was about displaying random images. I twiddled with image tags on a page so they pointed to different image files over time. It was a simple concept: You have an arbitrary number of images on a page, a few of which the computer would randomly change about five times a second. The effect was a flashing, mutating space that I liked a lot.

I didn’t know it back then, but what I was doing was manipulating the Document Object Model of that page. I had a number of objects on the page. My script would then query out the number of images, and then modify an attribute of that object (i.e., switch out the sources of the images).

This was about the limit of what you could do with the Document Object Model in Netscape 3. You could read and write the attributes of image and anchor tags, and you could query some information about the browser itself – what MIME-types it accepted, what plug-ins were installed, its location, and a few other things. Simple, basic, down-to-earth, level-zero items.

Continue Reading “Building with the Document Object Model” »
File Under: HTML, Web Standards

Make an HTML Document

HTML is the lingua franca of the web. It’s a simple, universal mark-up language that allows web publishers to create complex pages of text and images that can be viewed by anyone else on the web, regardless of what kind of computer or browser is being used.

Despite what you might have heard, you don’t need any special software to create an HTML page; all you need is a word processor (such as SimpleText, BBEdit, or Microsoft Word) and a working knowledge of HTML. And lucky for all of us, basic HTML is dead easy.

It’s All About the Tags

HTML is just a series of tags that are integrated into a text document. They’re a lot like stage directions — silently telling the browser what to do, and what props to use. Continue Reading “Make an HTML Document” »

File Under: Glossary

Lists

The level of sophistication used to format lists in HTML is a vestige of HTML’s roots as a text-formatting language. You can’t position images or manipulate the leading of type yet, but you can make three types of lists:the unordered list (which is like an outline), the ordered list (which is like numbered instructions), and the definition list (which is like a series of dictionary entries).

File Under: Glossary

Action

Action is a Form attribute that communicates with the common gateway interface (CGI) program to process.

For example, if you entered “bananas” to the following form:

<form action="../processor.cgi">

Please process this:

    <input name=food><br>



    <input type=submit>

</form>

The HTML form would send the input “bananas” to the cgi script. To the cgi script, the action would look like: ../processor.cgi?food=bananas

File Under: Glossary

Meta Information

Meta information means “information about information.”

In HTML, meta tags describe the content of the document in which they’re written. Meta tags have two possible attributes:
<META HTTP-EQUIV="name" CONTENT="content">
and
<META NAME="name" CONTENT="content">
. Meta tags with an
HTTP-EQUIV
attribute are analogous to
HTTP
headers that can control the action of browsers. Meta tags with a
NAME
attribute are used primarily by indexing and searching tools. These tools can gather meta information in order to sort and classify web pages. One way to help your document show up more frequently in search engines and directories is to use the
META NAME
attribute to set keywords that will pull up your site when someone does a search for those words.