| Home News Product Order Forum Feedback Partner Profile | © Neatware 2000 |
| Neatware | Snaml |
|
HTML |
|
|
Last Update: Wed Apr 12 20:02:50 2000 |
|
Snaml Basic
Introduction Syntax Control Types Modules Status Snaml HTML HTML Structure Link Objects Text Font Snaml CSS CSS Script Snaml CGI CGI Variables Output Form Application Snaml XML XML Document EBNF |
HTML (HyperText Markup Language) is a standard for Web page. Element and its attributes are basic components of HTML. There are three types of element: start tag, end tag, and empty tag. The start and end tag has the format <element attribute> and </element> respectively. The text between the start tag and the end tag is called content. An element may have no end tag. An empty element has neither end tag nor content. An element name is always case-insensitive.
Attributes are properties of an element. The attribute='value' pairs are attached behind the start element name and inside the < >. Any number of attribute value pairs may be attached in arbitrary order. The attributes that are not used in the start tag are set to be default values. Boolean attribute may only have the value. Usually, double quotation mark " " and single quotation mark ' ' group the value. We prefer to use single quote ' ' as value grouping. To specify attribute name it is better to use letters, digits, hyphens and periods. Attribute name is case insensitive, but the case of a value may dependent on the definition of an element.
In Snaml, _element and element_ command with underscore in the head and end represent the start tag and the end tag. One argument of the start element command is its attribute. The empty element is represented as double underline element (__element). It specifies that no content and end tag are expected. The empty element in the HTML is the same as the start tag but in the XML there exist another expression.
__doctype command specifies the version number, language, and html standard. Three files, strict.dtd, loose.dtd, and frameset.dtd specify the HTML DTD (Document Type Definition) files. A HTML __doctype command example is
_html and html_ are start and end element of a HTML document. It is depreciated to set attributes on the _html start command since you can set the document and version information in the __doctype command. The simplest HTML document is
_head command specifies the human readable and machine readable head information of a HTML document. The _title command must appear inside the _head content. Other commands are optional.
A browser will display the value of the title attribute such as title='Document' on the title bar. Typically, 'title' attribute is used as a tooltip of a command.
_meta command sets machine readable information. Its 'name' attribute defines the property name; 'content' attribute defines the property value; 'scheme' attribute interprets the property value; 'lang' attribute specifies the language; and 'http-equiv' attribute provides HTTP server information for response header.
http-equiv may be used to wait seconds and refresh to another page. Following example waiting 2 seconds and switch to new URL in content.
When the name's value is a keyword, it is helpful to list a series of keywords in the content's value for search engine readable.
_body command specifies the content of a HTML document. The 'background' attribute may be an image or a color value; 'text' attribute is the color of the foreground text; 'link' attribute sets the color of text for unvisited hypertext link; 'vlink' sets the color of text for visited hypertext link; and 'alink' sets the color of text for user selected hypertext link. Using of _body's attributes is deprecated. Style sheets are now the preferred way to describe the presentation.
_h1 to _h6 are heading commands to describe the topic of a section. There are six levels. _h1 is the highest level (usually larger font) and _h6 is the lowest level. These commands are widely used with CSS.
The _div and _span commands offer a generic mechanism to construct structure documents. _div and _span define content to be block and inline respectively. By using 'classid' and 'id' attributes, authors may easily control the content in the block for presentation. _div and _span are prefered commands to separate structure and presentation.
|
|
|
|
Last Update: Wed Apr 12 20:02:50 2000 |
|
HTML |
| Neatware | Snaml |
| Home News Product Order Forum Feedback Partner Profile | © Neatware 2000 |