0% found this document useful (0 votes)
132 views3,310 pages

HTML Ref

Uploaded by

serg
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
132 views3,310 pages

HTML Ref

Uploaded by

serg
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3310

In html applications overvie...

DHTML, HTML & CS


Web Workshop | DHTML, HTML & CSS
HTML Applications Reference
Microsoft® Internet Explorer version 5 is the platform for developing html applications
I
(HTA). A number of object model extensions (HTA) enable the developer to customize an
application's user interface.

The following links provide access to HTA-specific functionality.

Elements HTA:APPLICATION
Properties applicationName
border
borderStyle
caption
commandLine
icon
maximizeButton
minimizeButton
showInTaskBar
singleInstance
sysMenu
version
windowState
Attributes APPLICATION

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
!Doctype Element DHTML References
Web Workshop | DHTML, HTML & CSS
DHTML Objects
The following is a list of the objects defined by Dynamic HTML. The links
take you to the object definitions, which contain the set of members for the
object.

!DOCTYPE A ACRONYM ADDRESS


APPLET AREA Attribute B
BASE BASEFONT BDO BGSOUND
BIG BLOCKQUOTE BODY BR
BUTTON CAPTION CENTER CITE
clientInformation clipboardData CODE COL
COLGROUP COMMENT currentStyle custom
dataTransfer DD DEL DFN
DIR DIV DL document
DT EM EMBED event
external FIELDSET FONT FORM
FRAME FRAMESET HEAD history
Hn HR HTML I
IFRAME IMG INPUT INS
ISINDEX KBD LABEL LEGEND
LI LINK LISTING location
MAP MARQUEE MENU META
navigator NEXTID NOBR NOFRAMES
NOSCRIPT OBJECT OL OPTION
P PARAM PLAINTEXT PRE
Q RT RUBY rule
runtimeStyle S SAMP screen
SCRIPT SELECT selection SMALL
SPAN STRIKE STRONG style
STYLE styleSheet SUB SUP
TABLE TBODY TD TEXTAREA
TextNode TextRange TextRectangle TFOOT
TH THEAD TITLE TR
TT U UL userProfile
VAR WBR window XML
XMP

Input Types

button checkbox file


hidden image password
radio reset submit text

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DHTML Properties
Web Workshop | DHTML, HTML & CSS
Internet Explorer 5.5 Properties
The following DHTML properties from the latest release of
Microsoft® Internet Explorer 5.5 are fully documented in
the MSDN® Online Web Workshop.

Property Description
contentEditable Sets or retrieves a string that indicates whether the user can edit
the content of the object.
scrollbar3dLightColor Sets or retrieves the color of the top and left edges of the scroll
box and scroll arrows of a scroll bar.
scrollbarArrowColor Sets or retrieves the color of the arrow element in a scroll arrow.
scrollbarBaseColor Sets or retrieves the color for elements of a scroll bar. If no other
properties are set, this property sets the color for all elements of
the scroll bar. If a specific scrollbar element property is set, it
overrides the scrollbarBaseColor setting for that element.
scrollbarDarkShadowColor Sets or retrieves the color of the gutter of a scroll bar. This color
occurs immediately outside the scrollBarShadowColor and affects
the bottom and right edges of the scroll box and scroll arrows.
scrollbarFaceColor Sets or retrieves the color of the scroll box and scroll arrows of a
scroll bar.
scrollbarHighlightColor Sets or retrieves the color for highlight areas in a scroll bar. This
affects the arrow element in the scroll arrow, and the top and left
edges of the scroll box and scroll arrows. If the
scrollbarTrackColor property is not set, highlight areas in the
track are affected.
scrollbarShadowColor Sets or retrieves the color of the bottom and right edges of the
scroll box and scroll arrows of a scroll bar.
scrollbarTrackColor Sets or retrieves the color of the track element of a scroll bar.
writingMode Sets or retrieves the direction and flow of the content in the
object.
zoom Sets or retrieves the magnification scale of the object.

Did you find this topic useful? Suggestions for other topics?
Write us!

© 2000 Microsoft Corporation. All rights reserved. Terms of


use .
DHTML References
Web Workshop | DHTML, HTML & CSS
Color Table
Colors can be specified in HTML pages in two ways—by using a
color name, or by using numbers to denote a red-green-blue
(RGB) color value. An RGB color value consists of three two-digit
hexadecimal numbers specifying the intensity of the corresponding
color.

For example, the color value #FF0000 is rendered red because the
red number is set to its highest value, FF (or 255 in decimal form).

Note While these color names might not be recognized by other


browsers, the RGB color values should display accurately across
browsers. When specifying color values for Web pages targeted to
work across different browsers, use the RGB color values.

The following table lists the colors supported as of Microsoft®


Internet Explorer 4.0.

aliceblue antiquewhite aqua aquamarine


(#F0F8FF) (#FAEBD7) (#00FFFF) (#7FFFD4)
azure
(#F0FFFF)
beige
(#F5F5DC)
bisque
(#FFE4C4) black
(#000000)
blanchedalmond
(#FFEBCD) blue blueviolet
(#8A2BE2) brown
(#0000FF) (#A52A2A)
burlywood cadetblue chartreuse chocolate
(#DEB887) (#5F9EA0) (#7FFF00) (#D2691E)
coral cornflower cornsilk crimson
(#FF7F50) (#6495ED) (#FFF8DC) (#DC143C)
cyan
(#00FFFF) darkblue darkcyan
(#008B8B)
darkgoldenrod
(#B8860B)
(#00008B)
darkgray
(#A9A9A9) darkgreen darkkhaki
(#BDB76B) darkmagenta
(#006400) (#8B008B)
darkolivegreen darkorange
(#FF8C00)
darkorchid
(#9932CC) darkred
(#556B2F) (#8B0000)
darksalmon
(#E9967A)
darkseagreen
(#8FBC8B) darkslateblue darkslategray
(#483D8B) (#2F4F4F)
darkturquoise darkviolet deeppink deepskyblue
(#00CED1) (#9400D3) (#FF1493) (#00BFFF)
dimgray
(#696969)
dodgerblue
(#1E90FF) firebrick floralwhite
(#FFFAF0)
(#B22222)
forestgreen fuchsia gainsboro ghostwhite
(#228B22) (#FF00FF) (#DCDCDC) (#F8F8FF)
gold goldenrod gray green
(#FFD700) (#DAA520) (#808080) (#008000)
greenyellow honeydew hotpink indianred
(#ADFF2F) (#F0FFF0) (#FF69B4) (#CD5C5C)

indigo ivory
(#FFFFF0)
khaki
(#F0E68C)
lavender
(#E6E6FA)
(#4B0082)
lavenderblush lawngreen lemonchiffon lightblue
(#FFF0F5) (#7CFC00) (#FFFACD) (#ADD8E6)
lightcoral lightcyan lightgoldenrodyellow lightgreen
(#F08080) (#E0FFFF) (#FAFAD2) (#90EE90)
lightgray lightpink lightsalmon lightseagreen
(#D3D3D3) (#FFB6C1) (#FFA07A) (#20B2AA)
lightskyblue lightslategray lightsteelblue lightyellow
(#87CEFA) (#778899) (#B0C4DE) (#FFFFE0)
lime limegreen linen magenta
(#00FF00) (#32CD32) (#FAF0E6) (#FF00FF)

maroon mediumaquamarine
(#66CDAA) mediumblue mediumorchid
(#BA55D3)
(#800000) (#0000CD)
mediumpurple mediumseagreen mediumslateblue mediumspringgreen
(#9370DB) (#3CB371) (#7B68EE) (#00FA9A)
mediumturquoise
(#48D1CC)
mediumvioletred
(#C71585) midnightblue mintcream
(#F5FFFA)
(#191970)
mistyrose
(#FFE4E1)
moccasin
(#FFE4B5)
navajowhite
(#FFDEAD) navy
(#000080)
oldlace olive olivedrab orange
(#FDF5E6) (#808000) (#6B8E23) (#FFA500)
orangered orchid palegoldenrod palegreen
(#FF4500) (#DA70D6) (#EEE8AA) (#98FB98)
paleturquoise palevioletred papayawhip peachpuff
(#AFEEEE) (#DB7093) (#FFEFD5) (#FFDAB9)
peru pink plum powderblue
(#CD853F) (#FFC0CB) (#DDA0DD) (#B0E0E6)

purple red
(#FF0000)
rosybrown
(#BC8F8F)
royalblue
(#4169E1)
(#800080)
saddlebrown salmon
(#FA8072)
sandybrown
(#F4A460)
seagreen
(#2E8B57)
(#8B4513)
seashell sienna silver skyblue
(#FFF5EE) (#A0522D) (#C0C0C0) (#87CEEB)
slateblue slategray snow springgreen
(#6A5ACD) (#708090) (#FFFAFA) (#00FF7F)
steelblue tan teal thistle
(#4682B4) (#D2B48C) (#008080) (#D8BFD8)
tomato turquoise violet wheat
(#FF6347) (#40E0D0) (#EE82EE) (#F5DEB3)
white whitesmoke yellow yellowgreen
(#FFFFFF) (#F5F5F5) (#FFFF00) (#9ACD32)
User-Defined System Colors
Microsoft® Windows® maintains a set of system colors for
painting various parts of the display. In addition to the colors
defined in the color table, as of Internet Explorer 4.0 these system
colors may also be specified as color values in Web pages.

Users can set system colors for future Windows sessions using the
Windows Control Panel. The following table illustrates the
correspondence of these color names with the colors defined in the
Control Panel.

Note The colors that do not correspond to any Control Panel colors
can only be set programmatically using Windows APIs and cannot
be defined by the user.

activeborder
activecaption appworkspace
background
buttonface buttonhighlight buttonshadow
buttontext
captiontext graytext
highlight highlighttext

inactiveborder inactivecaption inactivecaptiontext infobackground

infotext menu menutext scrollbar

threeddarkshadow threedface threedhighlight threedlightshadow

threedshadow window
windowframe windowtext

Did you find this topic useful? Suggestions for other topics? write
us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DHTML References
Web Workshop | DHTML, HTML & CSS
Command Identifiers
Command identifiers specify an action to take on the given
object. Use them with the following methods:

execCommand
queryCommandEnabled
queryCommandIndeterm
queryCommandState
queryCommandSupported
queryCommandValue
The following command identifiers are currently available:

BackColor Sets or retrieves the background color of the current selection.


Bold Toggles the current selection between bold and nonbold.
ClearAutocompleteForForms Clears saved forms data.
Copy Copies the current selection to the clipboard.
CreateBookmark Retrieves the name of a bookmark anchor or creates a bookmark anchor
for the current selection or insertion point.
CreateLink Retrieves the URL of a hyperlink or creates a hyperlink on the current
selection.
Cut Copies the current selection to the clipboard and then deletes it.
Delete Deletes the current selection.
Find Finds and selects text in the current document.
FontName Sets or retrieves the font for the current selection.
FontSize Sets or retrieves the font size for the current selection.
ForeColor Sets or retrieves the foreground (text) color of the current selection.
FormatBlock Sets or retrieves the current block format tag.
Indent Increases the indent of the selected text by one indentation increment.
InsertButton Overwrites a button control on the current selection.
InsertFieldset Overwrites a box on the current selection.
InsertHorizontalRule Overwrites a horizontal line on the current selection.
InsertIFrame Overwrites an inline frame on the current selection.
InsertImage Overwrites an image on the current selection.
InsertInputButton Overwrites a button control on the current selection.
InsertInputCheckbox Overwrites a check box control on the current selection.
InsertInputFileUpload Overwrites a file upload control on the current selection.
InsertInputHidden Inserts a hidden control on the current selection.
InsertInputImage Overwrites an image control on the current selection.
InsertInputPassword Overwrites a password control on the current selection.
InsertInputRadio Overwrites a radio control on the current selection.
InsertInputReset Overwrites a reset control on the current selection.
InsertInputSubmit Overwrites a submit control on the current selection.
InsertInputText Overwrites a text control on the current selection.
InsertMarquee Overwrites an empty marquee on the current selection.
InsertOrderedList Toggles the current selection between an ordered list and a normal
format block.
InsertParagraph Overwrites a line break on the current selection.
InsertSelectDropdown Overwrites a drop-down selection control on the current selection.
InsertSelectListbox Overwrites a list box selection control on the current selection.
InsertTextArea Overwrites a multiline text input control on the current selection.
InsertUnorderedList Toggles the current selection between an ordered list and a normal
format block.
Italic Toggles the current selection between italic and nonitalic.
JustifyCenter Centers the format block in which the current selection is located.
JustifyLeft Left-justifies the format block in which the current selection is located.
JustifyRight Right-justifies the format block in which the current selection is located.
Outdent Decreases by one increment the indentation of the format block in which
the current selection is located.
OverWrite Toggles the text-entry mode between insert and overwrite.
Paste Overwrites the contents of the clipboard on the current selection.
Refresh Refreshes the current document.
RemoveFormat Removes the formatting tags from the current selection.
SelectAll Selects the entire document.
UnBookmark Removes any bookmark from the current selection.
Underline Toggles the current selection between underlined and not underlined.
Unlink Removes any hyperlink from the current selection.
Unselect Clears the current selection.

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
DHTML References
Web Workshop | DHTML, HTML & CSS
Language Codes
The following table lists all the possible language codes
used to specify various system settings.

af Afrikaans sq Albanian
ar-sa Arabic (Saudi Arabia) ar-iq Arabic (Iraq)
ar-eg Arabic (Egypt) ar-ly Arabic (Libya)
ar-dz Arabic (Algeria) ar-ma Arabic (Morocco)
ar-tn Arabic (Tunisia) ar-om Arabic (Oman)
ar-ye Arabic (Yemen) ar-sy Arabic (Syria)
ar-jo Arabic (Jordan) ar-lb Arabic (Lebanon)
ar-kw Arabic (Kuwait) ar-ae Arabic (U.A.E.)
ar-bh Arabic (Bahrain) ar-qa Arabic (Qatar)
eu Basque bg Bulgarian
be Belarusian ca Catalan
zh-tw Chinese (Taiwan) zh-cn Chinese (PRC)
zh-hk Chinese (Hong Kong, S.A.R. China) zh-sg Chinese (Singapore)
hr Croatian cs Czech
da Danish nl Dutch (Standard)
nl-be Dutch (Belgium) en English
en-us English (United States) en-gb English (Great Britain)
en-au English (Australia) en-ca English (Canada)
en-nz English (New Zealand) en-ie English (Ireland)
en-za English (South Africa) en-jm English (Jamaica)
en English (Caribbean) en-bz English (Belize)
en-tt English (Trinidad) et Estonian
fo Faeroese fa Farsi
fi Finnish fr French (Standard)
fr-be French (Belgium) fr-ca French (Canada)
fr-ch French (Switzerland) fr-lu French (Luxembourg)
gd Gaelic (Scotland) gd-ie Gaelic (Ireland)
de German (Standard) de-ch German (Switzerland)
de-at German (Austria) de-lu German (Luxembourg)
de-li German (Liechtenstein) el Greek
he Hebrew hi Hindi
hu Hungarian is Icelandic
in Indonesian it Italian (Standard)
it-ch Italian (Switzerland) ja Japanese
ko Korean ko Korean (Johab)
lv Latvian lt Lithuanian
mk Macedonian (FYROM) ms Malaysian
mt Maltese no Norwegian (Bokmal)
no Norwegian (Nynorsk) pl Polish
pt-br Portuguese (Brazil) pt Portuguese (Portugal)
rm Rhaeto-Romanic ro Romanian
ro-mo Romanian (Moldavia) ru Russian
ru-mo Russian (Moldavia) sz Sami (Lappish)
sr Serbian (Cyrillic) sr Serbian (Latin)
sk Slovak sl Slovenian
sb Sorbian es Spanish (Spain – Traditional)
es-mx Spanish (Mexico) es Spanish (Spain – Modern)
es-gt Spanish (Guatemala) es-cr Spanish (Costa Rica)
es-pa Spanish (Panama) es-do Spanish (Dominican Republic)
es-ve Spanish (Venezuela) es-co Spanish (Colombia)
es-pe Spanish (Peru) es-ar Spanish (Argentina)
es-ec Spanish (Ecuador) es-cl Spanish (Chile)
es-uy Spanish (Uruguay) es-py Spanish (Paraguay)
es-bo Spanish (Bolivia) es-sv Spanish (El Salvador)
es-hn Spanish (Honduras) es-ni Spanish (Nicaragua)
es-pr Spanish (Puerto Rico) sx Sutu
sv Swedish sv-fi Swedish (Finland)
th Thai ts Tsonga
tn Tswana tr Turkish
uk Ukrainian ur Urdu
ve Venda vi Vietnamese
xh Xhosa ji Yiddish
zu Zulu

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
DHTML, HTML & CSS
For navigation tips, please see using this site .
I
Looking for technical information on using DHTML, HTML,
CSS, and associated technologies? In this area of the MSDN
Online Web Workshop you'll find articles, white papers, and
lessons that will help guide you through the thickets of web
page design.
HTML
For information on HTML, the best starting place is our html
beginner's guide . Here you'll find information on tags,
I
elements, setting font sizes, and the mysteries of markup
code. Next, have a look at authoring basics , where you'll
I
find answers to "Seven Questions You Should Never Fear to
Ask" and other information resources for beginners.
Seasoned pros who want to finesse their code can turn to
authoring effective pages and designing efficient pages
I I
for advanced tips on layout, design, and form.
DHTML
If you're looking to enhance your pages with DHTML, you'll
find a general introduction in our dynamic html overview
I
and faqs articles. These articles will show you how to use
I
DHTML to bring movement and interactivity to your web
pages. Web page designers who want to hot-rod their pages
should turn to boosting performance and building high
I
performance html pages for pointers on how to make web
I
pages more immediate and responsive. MSDN's DHTML
Dude answers questions on such subjects as positioning,
mouseover support, and baffling modal dialogues in his
dhtml dude questions and answers .
I
CSS
Working with Cascading Style Sheets? The css overview
I
provides an introductory look at DHTML, CSS, CSS
positioning, and font embedding. For a more complete
analysis of CSS, try out user's guide to style sheets .
I
HTML Help
Developers who create content for software programs,
multimedia titles, intranets, extranets, or for the Internet
often need to write HTML Help programs to go with their
products. The introducing html help guide provides
I
samples, software, and a helpful user's guide.

Finally, if you've been working with an HTML-related


technology and can't unravel a difficult problem in your
script, look to MSDN's knowledge base articles for detailed
I
answers to specific HTML, DHTML, and scripting issues.

© 1999 microsoft corporation. all rights reserved. terms of


use .
I
Welcome to Scriptlet Tech...
Web Workshop | Component
Development
Scriptlets Overview
A scriptlet is a Web page based on Dynamic HTML (DHTML)
that you can use as a control in any application that
supports controls. The scriptlet is a complete Web-ready
.htm file, but it includes information that allows you to work
with it as a control—you can get and set its properties, call
its methods, and so on.

Scriptlets:

Allow Web page authors to create reusable user


interface components without having to harness the
full power of C, C++, or other control-building
environments.
Allow developers using Microsoft Visual Basic®,
Microsoft Visual InterDev®, and other development
environments that support controls to make use of
features built into Web pages.
Are easy to create and maintain.
Are small and efficient.
For example, with scriptlets you can:

Use the graphical and hypertext capabilities of Web


pages as visually rich interfaces for your application.
Change the appearance and behavior of Web pages
from within the host environment. For example, you
can use a Visual Basic application to read information
from files and then write it into the scriptlet.
Prototype controls that you intend to write in other
environments. Because you can put scriptlets together
quickly and easily, you can test ideas. When you have
completed your design, you can reimplement the
control in another environment—such as C++, Visual
Basic, or J++—if you want greater performance or a
different means of packaging your control.
How Scriptlets Work
You use a scriptlet like a standard control. In the scriptlet,
you create any properties, methods, or events that you
want by simply creating scripts in common active scripting
languages such as JScript® (compatible with ECMA 262
language specification), Visual Basic Scripting Edition
(VBScript), or another language. The scripts rely on the
scripting capabilities of DHTML, which gives you a complete
object model for elements on the scriptlet.

For example, a scriptlet might be a Web page that contains


animation based on DHTML that moves and resizes text on
the page. You can write scripts to expose properties that
allow another application to set the text, speed, and
direction of the animation text, as well as methods that
allow another application to start, stop, and pause the
animation.

Note To learn more about using Dynamic HTML in your Web


pages, you can view the documentation for the Internet
Client SDK located at
http://msdn.microsoft.com/workshop/author/default.asp.

Support for scriptlets is built into Internet Explorer 4.0. You


can use the standard OBJECT tag to insert and work with
scriptlets as you do any other object on a Web page.

To use the scriptlet in applications that support ActiveX®


controls, you use a control called the scriptlet container
object, which hosts the scriptlet. The host application, such
as Visual Basic, uses the scriptlet container object to create
a window for the scriptlet and provide a way for the host
application to specify which scriptlet to use, where it
displays, at what size, and so on. The scriptlet container
object also provides the interface for you to set and get the
scriptlet's properties, call its methods, and respond to its
events.
Scriptlet Security
In a security-aware host application such as Internet
Explorer, the scriptlet and any controls contained within it
are subject to Internet Explorer 4.0 security. For
information about security settings in Internet Explorer 4.0,
see Internet Explorer Help.

Typically, the security settings for the zone containing the


scriptlet's server must be Medium or Low. If the setting is
High, the scriptlet will not download to your computer. If
you usually set custom security settings for a zone, set both
"Script ActiveX controls marked safe for scripting" and
"Initialize and script ActiveX controls not marked as safe" to
either Prompt or Enable.

The same applies to any controls that the scriptlet contains,


including other scriptlets, especially if the scriptlet contains
controls that reside on a server in a different zone.

When you distribute an application that uses a scriptlet,


make sure that users set the security settings in their copy
of Internet Explorer to the correct level to allow them to use
your scriptlets.

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Welcome to Scriptlet Tech...
Web Workshop | Component
Development
Designing and Using Scriptlets
You can easily create scriptlets and add them to your
applications.

To See
Choose a method for creating a scriptlet from your Web page Designing a Scriptlet
Use your scriptlet as a control Adding Scriptlets to Your Application
React to events in your applications Defining Event Handlers

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Welcome to Scriptlet Tech...
Web Workshop | Component
Development
Scriptlet Container Object Reference
When you work with scriptlets in your application, you can
use the following properties and events of the scriptlet
container object:

Properties
event
readyState
scrollbar
url
Events
onclick
ondblclick
onkeydown
onkeypress
onkeyup
onmousedown
onmousemove
onmouseup
onreadystatechange
onscriptletevent

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Welcome to Scriptlet Tech...
Web Workshop | Component
Development
Scriptlet Model Extensions
When creating the scripts in the scriptlet, you can use the
following specific extensions to the Dynamic HTML Object
Model. All extensions are available in the DHTML
window.external object.

Properties
frozen
selectableContent
version

Methods
bubbleEvent
raiseEvent
setContextMenu

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
CSS Length Units DHTML References
Web Workshop | DHTML, HTML & CSS
CSS Attributes Reference
This section defines the supported cascading style sheets (CSS) attributes.
An asterisk (*) indicates the attribute is available as of Microsoft® Internet
Explorer 5 or later. If an attribute or property has been proposed to the
World Wide Web Consortium (W3C) but not yet made standard, it is marked
as "proposed."

Behavior properties behavior (proposed)*


Font and text properties direction*
font
@font-face
font-family
font-size
font-style
font-variant
font-weight

ime-mode (proposed)*
layout-grid (proposed)
layout-grid-char (proposed)
layout-grid-char-spacing (proposed)
layout-grid-line (proposed)
layout-grid-mode (proposed)
layout-grid-type (proposed)

line-break (proposed)*
line-height
letter-spacing

ruby-align (proposed)*

ruby-overhang (proposed)*

ruby-position (proposed)*
text-align
text-decoration

text-justify (proposed)*
text-indent
text-transform
unicode-bidi
vertical-align

word-break (proposed)*
word-spacing (Macintosh only)
Color and background properties background
background-attachment
background-color
background-image
background-position
background-repeat
color
Layout properties border
border-bottom
border-bottom-color
border-bottom-style
border-bottom-width

border-collapse*
border-color
border-left
border-left-color
border-left-style
border-left-width
border-right
border-right-color
border-right-style
border-right-width
border-style
border-top
border-top-color
border-top-style
border-top-width
border-width
clear
float
margin
margin-bottom
margin-left
margin-right
margin-top
padding
padding-bottom
padding-left
padding-right
padding-top

table-layout*
Classification properties display
list-style
list-style-image
list-style-position
list-style-type
Positioning properties bottom
clip
height
left
overflow
overflow-x (proposed)
overflow-y (proposed)
position
right
top
visibility
width
z-index
Printing properties page-break-after
page-break-before
Filter properties filter (proposed)
Pseudo-classes and other properties active
cursor
hover
@import
!important
link
visited
Unsupported CSS attributes first-letter pseudo
first-line pseudo
white-space

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CSS Attributes Reference DHTML References
Web Workshop | DHTML, HTML & CSS
CSS Length Units
This section defines the supported length units for CSS attributes. Unless otherwise
specified, the length units are supported as of Microsoft® Internet Explorer 3.0 or later.
An asterisk (*) indicates the length unit is available as of Internet Explorer 4.0 or later.

Relative length units

em * The height of the element's font.

ex * The height of the letter "x".


px Pixels.
% Percentage.
Absolute length units
in Inches (1 inch = 2.54 centimeters).
cm Centimeters.
mm Millimeters.
pt Points (1 point = 1/72 inches).
pc Picas (1 pica = 12 points).

Measurements and positions in cascading style sheets (CSS) properties are indicated in
length units. Internet Explorer supports two types of length units: relative and absolute.

A relative length unit specifies a length in relation to another length property. Relative
length units scale better from one output device to another, such as from a monitor to a
printer.

An absolute length unit specifies an absolute measurement, such as inches or


centimeters. Absolute length units are useful when the physical properties of the output
device are known.

See Also

CSS Attributes Reference

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
The Web Workshop is only available from
the live MSDN Online Web site.

This page will automatically take you the Web Workshop


on the MSDN Online Web site, or click here to
I
immediately jump to the page.
The Web Workshop is only available from
the live MSDN Online Web site.

This page will automatically take you the Web


Workshop on the MSDN Online Web site, or
click here to immediately jump to the page.
I
In html applications overvie...Int APPLICATION Attri
Web Workshop | DHTML, HTML & CSS
HTA:APPLICATION Element | HTA:APPLICATION Object
Enables an extended object model for building HTML Applications (HTA).

Members

Remarks

You can create an HTA by saving an HTML page with an .hta file extension. However, to
take advantage of the applications-oriented functionality discussed in this reference,
you must include the HTA:APPLICATION tag and position it within the paired HEAD
tag to take effect.

You can turn off the scroll bars for the application window by including SCROLL="no" in
the BODY tag.

Example

This example retrieves all the properties exposed by HTA:APPLICATION.

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
APPLICATION Attribute BORDER Attribute | bor
Web Workshop | DHTML, HTML & CSS
APPLICATIONNAME Attribute | applicationName Property
Retrieves the name of the HTML Application (HTA).

Syntax

HTML <HTA:APPLICATION APPLICATIONNAME=sAppName>


Scripting [ sAppName = ] oHTA.applicationName

Possible Values

sAppName String that specifies the application name.

The property is read-only with no default value.

Remarks

When set to true, the singleInstance property checks the applicationName value
before launching an instance of the application. For this check to be valid, the
applicationName property must have a unique value assigned to it. You can use the
applicationName property to identify a single application, regardless of the URL used
to access it.

Example

This example shows how to retrieve the applicationName property.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
>
<SCRIPT>
alert("applicationName = " + oHTA.applicationName);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

HTA:APPLICATION
See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
APPLICATIONNAME Attribute... BORDERSTYLE A
Web Workshop | DHTML, HTML & CSS
BORDER Attribute | border Property
Retrieves the type of window border for the HTML Application (HTA).

Syntax

HTML <HTA:APPLICATION BORDER=sType>


Scripting [ sType = ] oHTA.border

Possible Values

sType String that specifies one of the following values:


thick Thick window border, plus a size grip and sizing border for resizing the window.
dialog Dialog window border.
none No window border.
thin Thin window border with a caption.

The property is read-only with a default value of thick.

Remarks

The border property affects the window border and is valid only for HTA windows that
contain a title bar or caption. Setting border to none eliminates the title bar, program
icon, and Minimize/Maximize buttons. This property can be used with the borderStyle
property, which controls the content border within the window.

Example

This example uses the border property to apply a thin border to the window.

<HTML>
<HEAD>
<TITLE>Hello, World!</TITLE>
<HTA:APPLICATION ID="oHTA"
APPLICATIONAME="myApp"
BORDER="thin"
>
<SCRIPT>
alert("border = " + oHTA.border);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.
Applies To

HTA:APPLICATION

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BORDER Attribute | border... CAPTION Attribute
Web Workshop | DHTML, HTML & CSS
BORDERSTYLE Attribute | borderStyle Property
Retrieves the style set for the content border within the HTML Application (HTA) window.

Syntax

HTML <HTA:APPLICATION BORDERSTYLE=sStyle>


Scripting [ sStyle = ] oHTA.borderStyle

Possible Values

sStyle String that specifies one of the following values:


normal Normal border.
complex Raised and sunken border.
raised Raised 3-D border.
static 3-D border typically used for windows that do not accept user input.
sunken Sunken 3-D border.

The property is read-only with a default value of normal.

Remarks

All HTAs have two adjacent borders: one for the content of a window, and one for the
application window. The borderStyle property sets the style for the content border,
while the border property controls the application window border.

Example

This example uses the borderStyle property to apply a normal border around the
content of a window.

Applies To

HTA:APPLICATION

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BORDERSTYLE Attribute | b... commandLine Pr
Web Workshop | DHTML, HTML & CSS
CAPTION Attribute | caption Property
Retrieves whether the window is set to display a title bar, or caption, for the HTML
Application (HTA).

Syntax

HTML <HTA:APPLICATION CAPTION=bTitleBar>


Scripting [ bTitleBar = ] oHTA.caption

Possible Values

bTitleBar Boolean that specifies one of the following values:


yes Title bar is displayed.
no Title bar is not displayed.

The property is read-only with a default value of yes.

Remarks

The application title appears only when the caption property is set to yes. Turning off
the caption also disables the program icon and the Minimize and Maximize buttons. In
this case, you must provide an alternate way for the user to quit the HTA, such as a
button that invokes the close method of the window object.

Example

This example shows how to retrieve the caption property.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
CAPTION="yes"
>
<SCRIPT>
alert ("caption = " + oHTA.caption);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest caption. Then reload this page to view the sample.

Applies To
HTA:APPLICATION

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CAPTION Attribute | capti... ICON Attribute | ic
Web Workshop | DHTML, HTML & CSS
commandLine Property
Retrieves the argument used to launch the HTML Application (HTA).

Syntax

HTML N/A
Scripting [ sPath = ] oHTA.commandLine

Possible Values

sPath String that specifies the path and arguments used to launch the HTA.

The property is read-only with no default value.

Remarks

The commandLine property returns an empty string when the HTA is launched over
the http protocol .
I
Example

This example shows how to retrieve the commandLine property value.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
>
<SCRIPT>
alert("commandLine = " + oHTA.commandLine);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

HTA:APPLICATION

See Also

html applications overview


I
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
commandLine Property MAXIMIZEBUTTON Attri
Web Workshop | DHTML, HTML & CSS
ICON Attribute | icon Property
Retrieves the name and location of the icon specified in the HTML Application (HTA).

Syntax

HTML <HTA:APPLICATION ICON=sIcon>


Scripting [ sIcon = ] oHTA.icon

Possible Values

sIcon String that specifies an icon for the application.

The property is read-only with a default value of the system application icon.

Remarks

The icon attribute recognizes the standard 32x32 pixel Microsoft® Windows® format
for .ico image files.

Example

This example shows how to retrieve the icon property.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
ICON="graphics/face01.ico"
>
<SCRIPT>
alert ("icon = " + oHTA.icon);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Microsoft® Internet Explorer 5 or later. Click the icon below to
install the latest version. Then reload this page to view the sample.

Applies To

HTA:APPLICATION

See Also

html applications overview


I
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ICON Attribute | icon Pro... MINIMIZEBUTTON A
Web Workshop | DHTML, HTML & CSS
MAXIMIZEBUTTON Attribute | maximizeButton Property
Retrieves whether a Maximize button is displayed in the title bar of the HTML Application
(HTA) window.

Syntax

HTML <HTA:APPLICATION MAXIMIZEBUTTON=bShowButton>


Scripting [ bShowButton = ] oHTA.maximizeButton

Possible Values

bShowButton Boolean that specifies one of the following values:


yes Maximize button is displayed.
no Maximize button is not displayed.

The property is read-only with a default value of yes.

Remarks

The window must have a title bar, or caption, for the Minimize and Maximize buttons to
display.

Example

This example shows how to retrieve the maximizeButton property.

<HTML>
<HEAD>
<TITLE>Hello, World!</TITLE>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
CAPTION="yes"
MAXIMIZEBUTTON="yes"
>
<SCRIPT>
alert("maximizeButton = " + oHTA.maximizeButton);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Microsoft® Internet Explorer 5 or later. Click the icon below to
install the latest version. Then reload this page to view the sample.

Applies To
HTA:APPLICATION

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
MAXIMIZEBUTTON Attribute ... SHOWINTASKBA
Web Workshop | DHTML, HTML & CSS
MINIMIZEBUTTON Attribute | minimizeButton Property
Retrieves whether a Minimize button is displayed in the title bar of the HTML Application
(HTA) window.

Syntax

HTML <HTA:APPLICATION MINIMIZEBUTTON=bShowButton>


Scripting [ bShowButton = ] oHTA.minimizeButton

Possible Values

bShowButton Boolean that specifies one of the following values:


yes Minimize button is displayed.
no Minimize button is not displayed.

The property is read-only with a default value of yes.

Remarks

The window must have a title bar, or caption, for the Minimize and Maximize buttons to
display.

Example

This example shows how to retrieve the minimizeButton property.

<HTML>
<HEAD>
<TITLE>Hello, World!</TITLE>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
CAPTION="yes"
MINIMIZEBUTTON="yes"
>
<SCRIPT>
alert ("minimizeButton = " + oHTA.minimizeButton);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Microsoft® Internet Explorer 5 or later. Click the icon below to
install the latest version. Then reload this page to view the sample.

Applies To
HTA:APPLICATION

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
MINIMIZEBUTTON Attribute ... SINGLEINSTANC
Web Workshop | DHTML, HTML & CSS
SHOWINTASKBAR Attribute | showInTaskBar Property
Retrieves whether the HTML Application (HTA) is displayed in the Microsoft® Windows®
taskbar.

Syntax

HTML <HTA:APPLICATION SHOWINTASKBAR=bShow>


Scripting [ bShow = ] oHTA.showInTaskBar

Possible Values

bShow Boolean that specifies one of the following values:


yes Application is displayed in the Windows taskbar.
no Application is not displayed in the Windows taskbar.

The property is read-only with a default value of yes.

Remarks

The showInTaskBar property does not affect whether the application appears in the
list of applications displayed when the user presses ALT+TAB.

Example

This example shows how to retrieve the showInTaskBar property.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
SHOWINTASKBAR="no"
>
<SCRIPT>
alert ("showInTaskBar = " + oHTA.showInTaskBar);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Microsoft® Internet Explorer 5 or later. Click the icon below to
install the latest version. Then reload this page to view the sample.

Applies To

HTA:APPLICATION
See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SHOWINTASKBAR Attribute |... SYSMENU Attrib
Web Workshop | DHTML, HTML & CSS
SINGLEINSTANCE Attribute | singleInstance Property
Retrieves whether only one instance of the specified HTML Application (HTA) can run at a
time.

Syntax

HTML <HTA:APPLICATION SINGLEINSTANCE=bOpen>


Scripting [ bOpen = ] oHTA.singleInstance

Possible Values

bOpen Boolean that specifies one of the following values:


yes Only one instance of the specified application can run at a time.
no Multiple instances of the specified application can run at the same time.

The property is read-only with a default value of no.

Remarks

When set to true, the singleInstance property checks the value of the
applicationName property before launching an instance of the application. For this
check to be valid, the applicationName property must have a unique value assigned
to it. You can use the applicationName property to identify a single application,
regardless of the URL used to access it.

Example

This example shows how to retrieve the singleInstance property.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
SINGLEINSTANCE="yes"
>
<SCRIPT>
alert("singleInstance = " + oHTA.singleInstance);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.
Applies To

HTA:APPLICATION

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SINGLEINSTANCE Attribute ... VERSION Attribu
Web Workshop | DHTML, HTML & CSS
SYSMENU Attribute | sysMenu Property
Retrieves whether a system menu is displayed in the HTML Application (HTA).

Syntax

HTML <HTA:APPLICATION SYSMENU=bMenu>


Scripting [ bMenu = ] oHTA.sysMenu

Possible Values

bMenu Boolean that specifies one of the following values:


yes System menu is displayed in the title bar.
no System menu is not displayed in the title bar.

The property is read-only with a default value of yes.

Remarks

The HTA system menu is denoted by the program icon on the far left corner of the title
bar. When clicked, the HTA system menu displays all the commands included in the
standard Microsoft® Windows® system menu, including restore, move, size, minimize,
maximize, and close.

Many of the properties that affect the user interface of the window are interdependent.
For example, setting sysMenu to no disables the program icon and the Minimize and
Maximize buttons. Similarly, setting the border property to none disables the program
icon, title bar, and Minimize and Maximize buttons.

Example

This example shows how to retrieve the sysMenu property.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
SYSMENU="yes"
>
<SCRIPT>
alert("sysMenu = " + oHTA.sysMenu);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>
This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

HTA:APPLICATION

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SYSMENU Attribute | sysMe... WINDOWSTATE A
Web Workshop | DHTML, HTML & CSS
VERSION Attribute | version Property
Retrieves the version number of the HTML Application (HTA).

Syntax

HTML <HTA:APPLICATION VERSION=sVersion>


Scripting [ sVersion = ] oHTA.version

Possible Values

sVersion String that specifies the version number of the application.

The property is read-only with a default value of an empty string.

Example

This example shows how to retrieve the version property.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
VERSION="1.0"
>
<SCRIPT>
alert("version = " + oHTA.version);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Microsoft® Internet Explorer 5 or later. Click the icon below to
install the latest version. Then reload this page to view the sample.

Applies To

HTA:APPLICATION

See Also

html applications overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
VERSION Attribute | versi... HTML Applications
Web Workshop | DHTML, HTML & CSS
WINDOWSTATE Attribute | windowState Property
Sets or retrieves the initial size of the HTML Application (HTA) window.

Syntax

HTML <HTA:APPLICATION WINDOWSTATE=sWindowSize>


Scripting oHTA.windowState[ = sWindowSize ]

Possible Values

sWindowSize String that specifies one of the following values:


normal Window is the default size for Microsoft Internet Explorer.
minimize Window does not display on launch. Instead, the title of the minimized application appears in the
taskbar.
maximize Window is sized to fill the screen.

The property is read/write with a default value of normal.

Example

This example shows how to retrieve the windowState property.

<HTML>
<HEAD>
<HTA:APPLICATION ID="oHTA"
APPLICATIONNAME="myApp"
WINDOWSTATE="maximize"
>
<SCRIPT>
alert("windowState = " + oHTA.windowState);
</SCRIPT>
</HEAD>
<BODY SCROLL="no">

</BODY>
</HTML>

This feature requires Microsoft® Internet Explorer 5 or later. Click the icon below to
install the latest version. Then reload this page to view the sample.

Applies To

HTA:APPLICATION

See Also

html applications overview


I
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
HTA:APPLICATION APPLICATIONNAME Attribute
Web Workshop | DHTML, HTML & CSS
APPLICATION Attribute
Indicates whether the content of the FRAME or IFRAME object is an HTML Application
(HTA) and, therefore, exempt from the browser security model.

Syntax

HTML <ELEMENTAPPLICATION=bApplication ... >


Scripting N/A

Possible Values

bApplication Boolean that specifies one of the following values:


yes Treats all content of the FRAME or IFRAME as an HTA, in which case the content is trusted.
no Treats all content of the FRAME or IFRAME as part of an HTML document by applying the browser
security rules for unsafe content.

The attribute has a default value of no.

Remarks

The APPLICATION attribute can be used only in HTAs.

You can use the APPLICATION attribute to control the content of your Web pages.
For example, you can use the attribute to create an HTA that has one FRAME that
accesses unsafe content, such as Internet URLs, and another FRAME that accesses
safe content. You can also use the attribute for cross-domain scripting between HTA-
enabled frames.

A nested FRAME or IFRAME requires each container FRAME to be HTA-enabled (for


example, APPLICATION="yes") for the innermost FRAME or IFRAME to accept the
value of APPLICATION="yes". Take, for instance, an IFRAME that contains a frameset.
Each FRAME within the frameset qualifies as being nested. For the innermost FRAME
to be considered safe, it and each each parent FRAME must be declared as
APPLICATION="yes".

HTAs are designed to prevent each untrusted HTML FRAME and IFRAME from having
script access to the HTA that contains them. In the case of a non-HTA-enabled FRAME,
the highest level frame comprises the top window for each FRAME that it contains.
The window.top and window.self are the same for that FRAME. In addition, an unsafe
FRAME or IFRAME receives neither a referrer nor an opener URL from the parent
HTA. This means FRAME or IFRAME are not affected by the the parent window of the
containing HTA.

Applies To

FRAME, IFRAME

See Also
html applications overview , HTML Applications References
I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
A Element | A Object DHTML Objects
Web Workshop | DHTML, HTML & CSS
!DOCTYPE Element
Specifies the HTML document type definition (DTD) to which the document
corresponds.

Remarks

Different versions of the DTD can be used depending on the level of


compatibility the author wants to indicate.

The !DOCTYPE element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0.

Example

The first example uses the !DOCTYPE element to indicate compatibility


with the HTML 3.2 DTD, while the second uses it to indicate a strict
adherence to the HTML 4.0 DTD.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0
Strict//EN">

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
In dynamic htmlInt
Web Workshop | DHTML, HTML & CSS
DHTML References
The reference material accessed through the following links
will help you to create compelling Web pages.

Dynamic HTML Object Model References

Objects
Properties
Methods
Events
Collections
HTML References

Elements
Character Sets
CSS References

CSS Attributes
CSS Length Units
Additional References

Color Table
Command Identifiers
Default Behaviors Reference
Language Codes
Tips and Tricks
Visual Filters and Transitions Reference
Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
!DOCTYPE Element ACRONYM Element | ACRON
Web Workshop | DHTML, HTML & CSS
A Element | A Object
Designates the start or destination of a hypertext link.

Remarks

The A (anchor) element requires the href or the name property to be specified.

Both text and images can be included within an anchor. An image that is an anchor has
a border whose color indicates whether the link has been visited.

The A element is an inline element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

The following examples use the A element to link files, open a file, include an image as
part of a link, define an anchor, and invoke a function.

<-- Link to a server. -->


<A HREF="http://www.microsoft.com">Microsoft home page.</A>

<-- Link to a file in the same directory. -->


<A HREF="home.htm">home.htm</A>

<-- Open a file in the window specified by TARGET. -->


<A TARGET="viewer" HREF="sample.htm">Open in window</A>

<-- Include an IMG element as a part of the link. -->


<A HREF="http://www.microsoft.com"><IMG
SRC="images/bullet.gif">link</A>

<-- Link to an anchor. -->


<A HREF="#anchor">anchor</A>

<-- Define an anchor. -->


<A NAME="anchor">

<-- Invoke a JScript function -->


<A HREF="javascript:window.open()">link</A>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
A Element | A Object ADDRESS Element | ADD
Web Workshop | DHTML, HTML & CSS
ACRONYM Element | ACRONYM Object
Indicates an acronym abbreviation.

Remarks

The ACRONYM element is an inline element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Example

<ACRONYM>MSN</ACRONYM>

See Also

ADDRESS, CITE, DFN, EM, I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ACRONYM Element | ACRONYM... APPLET Elem
Web Workshop | DHTML, HTML & CSS
ADDRESS Element | ADDRESS Object
Specifies information, such as address, signature, and authorship, of the current
document.

Remarks

Microsoft® Internet Explorer displays the content of an ADDRESS element in italics.

The ADDRESS element is a block element and requires a closing tag.

This element is available in HTML as of Internet Explorer 3.0, and in script as of


Internet Explorer 4.0.

Members

Example

This example uses the ADDRESS element to italicize text.

<ADDRESS>This text will be italic.</ADDRESS>

See Also

ACRONYM, CITE, DFN, EM, I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ADDRESS Element | ADDRESS... AREA Element
Web Workshop | DHTML, HTML & CSS
APPLET Element | APPLET Object
Places executable content on the page.

Remarks

The APPLET element is a block element and requires a closing tag.

To use executable content specified by the APPLET element, a user's computer must
have the Microsoft virtual machine installed.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
APPLET Element | APPLET O... Attribute Object
Web Workshop | DHTML, HTML & CSS
AREA Element | AREA Object
Defines the shape, coordinates, and associated URL of one hyperlink region within a client-
side image MAP.

Remarks

Any number of AREA elements can be contained within the same MAP element.

The format of the COORDS value depends on the value of the SHAPE attribute.

The AREA element is not rendered and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example provides the code for an image map of the solar system. It creates links
from the image map to individual images of the planets using the AREA element with
the MAP element, COORDS value, and SHAPE attribute. The user clicks the sun or
any planet to link to an individual image. To return to the solar system image map, the
user clicks the Back button.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
AREA Element | AREA Objec... B Element | B O
Web Workshop | DHTML, HTML & CSS
Attribute Object
Represents an attribute or property of an HTML element as an object.

Remarks

The Attribute object is accessible through the attributes collection.

A valid attribute or property can be any Dynamic HTML (DHTML) property or event that
applies to the object, or an expando.

This object is available in script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the Attribute object to create a list of attributes that are specified.

<SCRIPT>
function fnFind(){
for(var i=0;i<oList.attributes.length;i++){
if(oList.attributes[i].specified){
alert(oList.attributes[i].nodeName + " = "
+ oList.attributes[i].nodeValue);
}
}
}
</SCRIPT>

<UL onclick="fnFind()">
<LI ID = "oItem1" ACCESSKEY = "L">List Item 1
</UL>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Attribute Object BASE Element | BASE Objec...
Web Workshop | DHTML, HTML & CSS
B Element | B Object
Specifies that the text should be rendered in bold.

Remarks

The B element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the B element to boldface the text.

<B>This text displays boldface.</B>

See Also

STRONG

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
B Element | B Object BASEFONT Element | BAS
Web Workshop | DHTML, HTML & CSS
BASE Element | BASE Object
Specifies an explicit URL used to resolve links and references to external sources such as
images and style sheets.

Remarks

When used, the BASE element must appear within the HEAD of the document, before
any elements that refer to an external source.

The BASE element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example sets the base URL of the document to a reference folder. Internet
Explorer uses the BASE element to resolve the link to
http://msdn.microsoft.com/workshop/author/dhtml/reference/properties/href_2.asp.

<HEAD>
<BASE
HREF="http://msdn.microsoft.com/workshop/author/dhtml/reference"
>
</HEAD>

<BODY>
Click <A HREF="properties/href_2.asp">here< to learn about the
href property.
</BODY>

This example retrieves the base URL from the document if a valid BASE element is
specified in the document. Otherwise, the function returns null.

<SCRIPT>
function GetBase()
{
var oBaseColl = document.all.tags('BASE');
return ( (oBaseColl && oBaseColl.length) ? oBaseColl[0].href
:
null );
}
</SCRIPT>
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BASE Element | BASE Objec... BDO Element | B
Web Workshop | DHTML, HTML & CSS
BASEFONT Element | BASEFONT Object
Sets a base font value to be used as the default font when rendering text.

Remarks

This element can be used only within the BODY element or the HEAD element.
BASEFONT should appear before any displayed text in the BODY of the document.

The BASEFONT element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the BASEFONT element to set the base font size, and the FONT
element to temporarily override it.

No BASEFONT size specified yet.


<BASEFONT SIZE=4> Set the BASEFONT size.
<FONT SIZE=2> Temporarily override the BASEFONT size.</FONT>
Resume the BASEFONT size.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BASEFONT Object | BASEFON... BGSOUND Obj
Web Workshop | DHTML, HTML & CSS
BDO Element | BDO Object
Allows authors to disable the bidirectional algorithm for selected fragments of text.

Remarks

The BDO element can be used to control the reading order of a block of text.

The Unicode bidirectional algorithm automatically reverses embedded character


sequences according to their inherent direction. For example, the base direction of an
English document is left-to-right (ltr). If portions of a paragraph within this document
contain a language with the right-to-left (rtl) reading order, you can reverse the
direction of that language by applying the bidirectional algorithm.

The bidirectional algorithm and the DIR attribute generally suffice for embedded
direction changes. However, incorrect presentations can occur when you expose
formatted text to the bidirectional algorithm. For example, a paragraph containing
English and Hebrew that is formatted for e-mail could be incorrectly inverted by the
bidirectional algorithm. Because the reading order of the Hebrew text was inverted
once for the e-mail, exposing it to the bidirectional algorithm would invert the words a
second time.

The BDO element turns off the algorithm and controls the reading order. The DIR
attribute is required when you use the BDO element.

The BDO element is an inline element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 5.

Members

Example

See Also

direction

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BDO Element | BDO Object BIG Element | BIG
Web Workshop | DHTML, HTML & CSS
BGSOUND Element | BGSOUND Object
Enables pages with background sounds or soundtracks to be created.

Remarks

The BGSOUND element can be used only within the HEAD element.

The BGSOUND element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BGSOUND Element | BGSOUND... BLOCKQUOT
Web Workshop | DHTML, HTML & CSS
BIG Element | BIG Object
Specifies that the enclosed text should be displayed in a larger font than the current font.

Remarks

The BIG element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the BIG element to enlarge text.

<BIG>This text is larger</BIG> than this text.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BIG Element | BIG Object BODY Element | bod
Web Workshop | DHTML, HTML & CSS
BLOCKQUOTE Element | BLOCKQUOTE Object
Sets apart a quotation in text.

Remarks

The BLOCKQUOTE element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the BLOCKQUOTE element to set off a quotation that renders as
indented text.

<P>He said,
<BLOCKQUOTE>"Hi there!"</BLOCKQUOTE>

See Also

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BLOCKQUOTE Element | BLOC... BR Element |
Web Workshop | DHTML, HTML & CSS
BODY Element | body Object
Specifies the beginning and end of the document body.

Remarks

You can access the BODY element from script through the document object.

The window object for the BODY element can host event handlers for the onblur,
onfocus, onload, or onunload events.

The BODY element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example exposes the BODY element in script.

var oBody = document.body;

Applies To

document

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BODY Element | body Objec... BUTTON Elemen
Web Workshop | DHTML, HTML & CSS
BR Element | BR Object
Inserts a line break.

Remarks

The BR element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BR Element | BR Object CAPTION Element | CA
Web Workshop | DHTML, HTML & CSS
BUTTON Element | BUTTON Object
Specifies a container for rich HTML that is rendered as a button.

Remarks

When the BUTTON element is submitted in a form, Microsoft® Internet Explorer 5 and
later submits the VALUE attribute, if it exists. Otherwise, the innerText property is
submitted. In Internet Explorer 4.0, only the innerText value is submitted.

The BUTTON element is an inline element and requires a closing tag.

This element is available in HTML and script as of Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BUTTON Element | BUTTON O... CENTER Eleme
Web Workshop | DHTML, HTML & CSS
CAPTION Element | CAPTION Object
Specifies a brief description for a TABLE.

Remarks

The CAPTION element should be a child of the TABLE element.

The CAPTION element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the CAPTION element to provide a brief description for a table.

<TABLE>
<CAPTION VALIGN=BOTTOM>
This caption will appear below the table.
</CAPTION>
<TBODY>
<TR>
<TD>
This text is inside the table.
</TD>
</TR>
</TBODY>
</TABLE>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CAPTION Element | CAPTION... CITE Element |
Web Workshop | DHTML, HTML & CSS
CENTER Element | CENTER Object
Centers subsequent text and images.

Remarks

The CENTER element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the CENTER element to center text on a page.

<CENTER>This text appears centered on the page.</CENTER>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CENTER Element | CENTER O... clientInformatio
Web Workshop | DHTML, HTML & CSS
CITE Element | CITE Object
Indicates a citation by rendering text in italic.

Remarks

A citation is a reference to a book, paper, or other published source material.

The CITE element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This examples uses the CITE element to render a citation in italic.

<CITE>Book Title.</CITE>

See Also

ACRONYM, ADDRESS, DFN, EM, I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CITE Element | CITE Objec... clipboardData Ob
Web Workshop | DHTML, HTML & CSS
clientInformation Object
Contains information about the Web browser.

Remarks

This object is available in script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example shows how to determine whether the userAgent of the browser contains
"MSIE". If it does, the browser is Internet Explorer.

<SCRIPT LANGUAGE="JScript">
if (window.clientInformation.userAgent.indexOf( "MSIE " ) > 0)
// The browser is Microsoft Internet Explorer.
</SCRIPT>

This example shows how to determine whether the browser can run Java applets.

<SCRIPT LANGUAGE="JScript">
if (window.clientInformation.javaEnabled() == true )
// Java is enabled; applets can run.
</SCRIPT>

Applies To

window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
clientInformation Object CODE Element | CODE
Web Workshop | DHTML, HTML & CSS
clipboardData Object
Provides access to predefined clipboard formats for use in editing operations.

Remarks

The clipboardData object is reserved for editing actions performed through the Edit
menu, shortcut menu, and shortcut keys. It transfers information using the system
clipboard and retains it until data from the next editing operation supplants it. This
form of data transfer is particularly suited to multiple pastes of the same data.

This object is available in script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the setData and getData methods with the clipboardData object
to perform a cut-and-paste operation through the shortcut menu.

Applies To

window

See Also

data transfer overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
clipboardData Object COL Element | COL Objec
Web Workshop | DHTML, HTML & CSS
CODE Element | CODE Object
Specifies a code sample.

Remarks

The CODE element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the CODE element to display text in a font used to represent
computer code, such as values or variable names.

<CODE>Here is some text in a small, fixed-width font.</CODE>

See Also

SAMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CODE Element | CODE Objec... COLGROUP Elem
Web Workshop | DHTML, HTML & CSS
COL Element | COL Object
Specifies column-based defaults for the table properties.

Remarks

The COL element is a block element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This examples uses the COL element to specify characteristics for default columns in a
table.

<TABLE>
<COLGROUP><COL ALIGN=RIGHT><COL ALIGN=LEFT></COLGROUP>
<COLGROUP><COL ALIGN=CENTER></COLGROUP>
<TBODY>
<TR>
<TD>This is the first column in the group and it is right-
aligned.</TD>
<TD>This is the second column in the group and it is left-
aligned.</TD>
<TD>This column is in a new group and it is centered.</TD>
</TR>
</TABLE>

See Also

COLGROUP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
COL Element | COL Object COMMENT Element
Web Workshop | DHTML, HTML & CSS
COLGROUP Element | COLGROUP Object
Contains a group of columns.

Remarks

The COLGROUP element is a block element and requires a closing tag if the
COLGROUP has COL elements nested within it; otherwise it does not require a closing
tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the COLGROUP element to assign specific characteristics to


columns in a table.

<TABLE>
<COLGROUP ALIGN="RIGHT"></COLGROUP>
<COLGROUP SPAN="2" ALIGN="LEFT"></COLGROUP>
<TBODY>
<TR>
<TD>This column is in the first group and is right-aligned.</TD>
<TD>This column is in the second group and is left-aligned.</TD>
<TD>This column is in the second group and is left-aligned.</TD>
</TR>
</TABLE>

See Also

COL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
COLGROUP Element | COLGRO... currentStyle O
Web Workshop | DHTML, HTML & CSS
COMMENT Element | COMMENT Object
Indicates a comment that is not displayed.

Remarks

The COMMENT element is treated as a no-scope element and does not expose any
children.

The COMMENT element requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

See Also

HTML Comment Element

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
COMMENT Element | COMMENT... custom Elem
Web Workshop | DHTML, HTML & CSS
currentStyle Object
Represents the cascaded format and style of the object as specified by global style sheets,
inline styles, and HTML attributes.

Remarks

The currentStyle object returns the cascaded styles on an element, but the style
object returns only the styles that have been applied inline on an element through the
STYLE attribute. Thus, the style values retrieved through the currentStyle object
might differ from the style values retrieved through the style object. For example, if
the color property is set on a paragraph only through a linked or embedded style
sheet, and not inline, then object.currentStyle.color returns the color, whereas
object.style.color does not return a value. If, however, the author specifies <P
STYLE="color:'red'">, the currentStyle and style objects return the value red.

The currentStyle object reflects the order of style precedence in cascading style
sheets (CSS). The CSS order of precedence for the presentation of HTML is:

1. Inline styles
2. Style sheet rules
3. Attributes on HTML tags
4. Intrinsic definition of the HTML tag

Accordingly, the currentStyle object returns the fontWeight value normal on a bold
tag if normal is specified in a style sheet.

The currentStyle object returns values that reflect the applied style settings for the
page and might not reflect what is rendering at the time a value is retrieved. For
example, an object that has "color:red; display:none" returns currentStyle.color
as red even though the object is not rendered on the page. The currentStyle object,
then, is not affected by the rendering constraints. The third example in the Example
section demonstrates this behavior. Disabled style sheets also do not affect
currentStyle values.

The returned value is in the same units as those used to set the object. For example, if
the color of an object is set inline using STYLE="color:'green'", then
object.currentStyle.color returns green and not #00FF00 (the red-green-blue
hexadecimal equivalent to green). However, capitalization and redundant white space
that appear in the object values set by the author are lost when the currentStyle
object returns the object values.

The currentStyle object supports user-defined properties in style rules. See the
second example in the Example section.
The currentStyle object is asynchronous. This means a style cannot be set and then
immediately queried—instead, the old value is returned. Thus, for a script to obtain the
expected behavior of currentStyle with methods such as addImport, the script needs
to include a function that calls the method and a function that checks currentStyle.
For a script to check the current style while a page is loading, the script must wait until
the BODY element is loaded and the page has rendered, or the value of currentStyle
might not reflect what is being displayed.

This object is available in script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the currentStyle object to set the text color to brown. If you click
a colored area and the background color is the same as the text color, the checkColor
function changes the background color, so the text can be read. Otherwise, the
function takes no action.

This example uses the currentStyle object to retrieve values of the user-defined
property created in the style rule. The alert returns the value myvalue.

This example shows that the TD object width returned by the currentStyle object is
its cascaded width value rather than the width rendered on the screen.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BGSOUND, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE,
CODE, COL, COLGROUP, COMMENT, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, HEAD, Hn, HTML, I, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, INS, ISINDEX, KBD, LABEL, LEGEND, LI, LINK, LISTING, MAP, MARQUEE, MENU, META, NEXTID, NOBR,
OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, STYLE, SUB, SUP, TABLE, TBODY, TD, TEXTAREA,
TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR, WBR, XMP

See Also

STYLE

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
currentStyle Object dataTransfer Object DHTM
Web Workshop | DHTML, HTML & CSS
custom Element | custom Object
Represents a user-defined element.

Remarks

Microsoft® Internet Explorer's support for custom tags on an HTML page requires that
a namespace be defined for the tag. Otherwise, the custom tag is treated as an
unknown tag when the document is parsed. Although navigating to a page with an
unknown tag in Internet Explorer does not result in an error, unknown tags have the
disadvantage of not being able to contain other tags, nor can they have behaviors
applied to them.

To declare a namespace, use the XMLNS attribute of the HTML element.

When defining custom tags, you must enclose custom tag definitions within an @media
wrapper.

Custom tags become much more interesting when applied with a DHTML behavior.
dhtml behaviors (or behaviors) and styles are applied to elements on a page the
I
same way—using cascading style sheets (CSS) attributes. More specifically, the
proposed CSS behavior attribute allows a Web author to specify the location of the
behavior and apply that behavior to an element on a page.

The custom element is an inline element and requires a closing tag.

This element is available in HTML and script as of Internet Explorer 5.

Members

Example

This example uses the custom element to create custom RED, GREEN, and BLUE
elements. These elements change the color of the text to red, green, or blue,
depending on whether it is surrounded by RED, GREEN, or BLUE tags. In this example,
the RED, GREEN, and BLUE tags are defined within a namespace called CUSTOMTAG.

See Also

using custom tags in internet explorer


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
custom Element | custom O... DD Element | DD
Web Workshop | DHTML, HTML & CSS
dataTransfer Object
Provides access to predefined clipboard formats for use in drag-and-drop operations.

Remarks

The dataTransfer object makes it possible to customize the handling of drag-and-


drop operations. It is available through the event object.

The dataTransfer object is used in source and target events. Typically, the setData
method is used with source events to provide information about the data being
transferred. In contrast, the getData method is used with target events to stipulate
which data and data formats to retrieve.

This object is available in script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the setData and getData methods of the dataTransfer object to
perform a drag-and-drop operation.

Applies To

event

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
dataTransfer Object DEL Element | DEL Object
Web Workshop | DHTML, HTML & CSS
DD Element | DD Object
Indicates the definition in a definition list. The definition is usually indented in the
definition list.

Remarks

The DD element is a block element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the DD element with the DL and DT elements to create a definition
list.

<DL>
<DT>Cat
<DD>A small domesticated mammal.
<DT>Lizard
<DD>A reptile generally found in dry areas.
</DL>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DD Element | DD Object DFN Element | DFN O
Web Workshop | DHTML, HTML & CSS
DEL Element | DEL Object
Indicates text that has been deleted from the document.

Remarks

The DEL element is an inline element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example uses the DEL element to mark deleted text.

<DEL>This text has been revised.</DEL>

See Also

INS

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DEL Element | DEL Object DIR Element | DIR O
Web Workshop | DHTML, HTML & CSS
DFN Element | DFN Object
Indicates the defining instance of a term.

Remarks

The DFN element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the DFN element to indicate a term definition.

<DFN>HTML stands for hypertext markup language.</DFN>

See Also

ACRONYM, ADDRESS, CITE, I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DFN Element | DFN Object DIV Element | DIV O
Web Workshop | DHTML, HTML & CSS
DIR Element | DIR Object
Denotes a directory list.

Remarks

The DIR element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the DIR element to create a directory list.

<DIR>
<LI>Art
<LI>History
<LI>Literature
<LI>Sports
<LI>Entertainment
<LI>Science
</DIR>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DIR Element | DIR Object DL Element | DL Obj
Web Workshop | DHTML, HTML & CSS
DIV Element | DIV Object
Specifies a container that renders HTML.

Remarks

The DIV element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses two DIV elements to align two sections of text differently.

<DIV>
This text represents a section.
</DIV>

<DIV ALIGN=CENTER>
This text represents another section, and its text is centered.
</DIV>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DIV Element | DIV Object document Object D
Web Workshop | DHTML, HTML & CSS
DL Element | DL Object
Denotes a definition list.

Remarks

The DL element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the DL element with the DD and DT elements to create a definition
list.

<DL>
<DT>Cat
<DD>A small domesticated mammal.
<DT>Lizard
<DD>A reptile generally found in dry areas.
</DL>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DL Element | DL Object DT Element | DT Objec
Web Workshop | DHTML, HTML & CSS
document Object
Represents the HTML document in a given browser window.

Remarks

Use the document object to retrieve information about the document, to examine and
modify the HTML elements and text within the document, and to process events.

The document object is available at all times. Retrieve the object by applying the
document property to a window or an element object. When used by itself, the
document object represents the document in the current window.

This object is available in script as of Microsoft® Internet Explorer 3.0.

Windows CE

In Microsoft® Windows® CE, the document object is not available through scripting
for a window opened using the open method.

Members

Example

This example uses the document object to check for a document title, and displays
the title (if not null) in a message box.

if (document.title!="")
alert("The title is " + document.title)

This example shows an event handler function that displays the current position of the
mouse, relative to the upper-left corner of the document, in the browser's status
window.

<HTML>
<HEAD><TITLE>Report mouse moves</TITLE>
<SCRIPT LANGUAGE="JScript">
function reportMove() {
window.status = "X=" + window.event.x + " Y=" +
window.event.y;
}
</SCRIPT>
<BODY onmousemove="reportMove()">
<H1>Welcome!</H1>
</BODY>
</HTML>
Applies To

custom, window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
document Object EM Element | EM Object DH
Web Workshop | DHTML, HTML & CSS
DT Element | DT Object
Indicates a definition term within a definition list.

Remarks

The DT element is a block element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the DT element with the DD and DL elements to create a definition
list.

<DL>
<DT>Cat
<DD>A small domesticated mammal.
<DT>Lizard
<DD>A reptile generally found in dry areas.
</DL>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DT Element | DT Object EMBED Element | EMB
Web Workshop | DHTML, HTML & CSS
EM Element | EM Object
Emphasizes text, usually by rendering it in italic.

Remarks

The EM element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the EM element to emphasize text.

<EM>This text will be emphasized in some way (most likely in


italic).</EM>

See Also

ACRONYM, ADDRESS, CITE, I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
EM Element | EM Object event Object DHTML
Web Workshop | DHTML, HTML & CSS
EMBED Element | EMBED Object
Allows documents of any type to be embedded.

Remarks

The EMBED element must appear inside the BODY element of the document.

Users need to have an application that can view the data installed on their computer.

The EMBED element is a block element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
EMBED Element | EMBED Obj... external Object
Web Workshop | DHTML, HTML & CSS
event Object
Represents the state of an event, such as the element in which the event occurred, the
state of the keyboard keys, the location of the mouse, and the state of the mouse buttons.

Remarks

The event object is available only during an event—that is, you can use it in event
handlers but not in other code.

Although all event properties are available to all event objects, some properties might
not have meaningful values during some events. For example, the fromElement and
toElement properties are meaningful only when processing the onmouseover and
onmouseout events.

In Microsoft® Visual Basic® Scripting Edition (VBScript), you must access the event
object through the window object.

This object is available in script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example uses the event object to check whether the user clicked the mouse
within a link, and to prevent the link from being navigated if the SHIFT key is down.

<HTML>
<HEAD><TITLE>Cancels Links</TITLE>
<SCRIPT LANGUAGE="JScript">
function cancelLink() {
if (window.event.srcElement.tagName == "A" &&
window.event.shiftKey)
window.event.returnValue = false;
}
</SCRIPT>
<BODY onclick="cancelLink()">

This example displays the current mouse position in the browser's status window.

<BODY onmousemove="window.status = 'X=' + window.event.x + '


Y='
+ window.event.y">

Applies To

window
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
event Object FIELDSET Element | FIELDS... D
Web Workshop | DHTML, HTML & CSS
external Object
Allows access to an additional object model provided by host applications of the Microsoft®
Internet Explorer browser components.

Remarks

In a hosting scenario, the object model is defined by the application hosting the
Internet Explorer components (refer to the hosting application for documentation). For
more information about how to implement extensions to the DHTML object model, see
extending the dynamic html object model .
I
This object is not supported in html applications .
I
This object is available in script as of Internet Explorer 4.0.

Members

Applies To

window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
external Object FONT Element | FONT Objec...
Web Workshop | DHTML, HTML & CSS
FIELDSET Element | FIELDSET Object
Draws a box around the text and other elements that the field set contains.

Remarks

This element is useful for grouping elements in a form and for distinctively marking
text in a document.

The FIELDSET element has the same behavior as a window frame. Since window
frames do not have scroll bars, assigning the overflow property a value of scroll will
render it as if the value were hidden.

The FIELDSET element is a block element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
FIELDSET Element | FIELDS... FORM Element |
Web Workshop | DHTML, HTML & CSS
FONT Element | FONT Object
Specifies a new font, size, and color to be used for rendering the enclosed text.

Remarks

The FONT element requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
FONT Element | FONT Objec... FRAME Element
Web Workshop | DHTML, HTML & CSS
FORM Element | FORM Object
Specifies that the contained controls take part in a form.

Remarks

Forms enable client-side users to submit data to a server in a standardized format. The
creator of a form designs the form to collect the required data using a variety of
controls, such as INPUT or SELECT. Users viewing the form fill in the data and then
click the Submit button to send the data to the server. A script on the server then
processes the data.

Each control element's NAME attribute must be defined if the data is to be submitted
with the form. An element in a form can be referenced by the NAME property or the
ID property, or through the elements collection.

When the focus is on a control in a form and the user presses ESC, the value of the
control reverts to the last value. The form resets if the user presses ESC again. If the
focus is on the form but not on a particular control and the user presses ESC once, the
form resets.

If the form includes only one text box and the user presses ENTER, the onsubmit event
fires. If the form has a Submit button, the button has a dark border, which indicates
the user can press ENTER to submit the form.

The FORM element is a block element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the FORM element to create a basic form containing a text entry
box for the user's name and a select control for choosing a favorite ice cream flavor.
When the user clicks the Submit button, the form sends the data to the URL listed in
the ACTION property. The value of the METHOD property determines how to send the
data to the server.

<HTML>
<FORM ACTION="http://example.microsoft.com/sample.asp"
METHOD="POST">
Enter your name: <INPUT NAME="FName"><BR>
Favorite Ice Cream Flavor:
<SELECT NAME="Flavor">
<OPTION VALUE="Chocolate">Chocolate
<OPTION VALUE="Strawberry">Strawberry
<OPTION VALUE="Vanilla" SELECTED>Vanilla
</SELECT>
<P><INPUT TYPE=SUBMIT>
</FORM>
</HTML>

See Also

1,001 ways to get input from web users


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
FORM Element | FORM Objec... FRAMESET Elem
Web Workshop | DHTML, HTML & CSS
FRAME Element | FRAME Object
Specifies an individual frame within a FRAMESET element.

Remarks

If a user opens a web folder inside a frame and then clicks something in the Web
I
folder, the file or folder that the user clicks takes over the entire window. For example,
suppose that a page contains two frames, one frame pointing to
http://www.microsoft.com and the second frame pointing to a network drive. If the
user clicks a file or folder in the second frame, that frame takes control of the entire
window, including the first frame. For file types that the browser cannot host, such as
.txt files, a separate window in the appropriate host application is opened.

A Web folder is a part of the file system hierarchy, but it does not necessarily represent
anything in the file system. An example is Network Neighborhood.

The FRAME element is a block element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the FRAME element to define properties of the frame, including the
location of the page loaded by the frame.

<FRAME FRAMEBORDER=0 SCROLLING=NO SRC="sample.htm">

This example shows how to reference an object with ID=sID in FRAME2, from another
frame of the same frameset.

parent.frames.FRAME2.sID.innertext

See Also

FRAMESET

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
FRAME Element | FRAME Obj... HEAD Element
Web Workshop | DHTML, HTML & CSS
FRAMESET Element | FRAMESET Object
Specifies a frameset, which is used to organize multiple frames and nested framesets.

Remarks

If a user opens a Web folder inside a frame and then clicks something in the Web
folder, the file or folder that the user clicks takes over the entire window. For example,
suppose that a page contains two frames, one frame pointing to
http://www.microsoft.com and the second frame pointing to a network drive. If the
user clicks a file or folder in the second frame, that frame takes control of the entire
window, including the first frame. For file types that the browser cannot host, such as
.txt files, a separate window in the appropriate host application is opened.

A Web folder is a part of the file system hierarchy, but it does not necessarily represent
anything in the file system. An example is Network Neighborhood.

The FRAMESET element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the FRAMESET element to define three columns of rectangular
frames on a page.

<FRAMESET COLS="25%, 50%, *">


<FRAME SRC="contents.htm">
<FRAME SRC="info.htm">
<FRAME SCROLLING="NO" SRC="graphic.htm">
</FRAMESET>

See Also

FRAME

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
FRAMESET Element | FRAMES... history Object
Web Workshop | DHTML, HTML & CSS
HEAD Element | HEAD Object
Provides an unordered collection of information about the document.

Remarks

The HEAD element provides information that does not affect the rendering of the
document but could be of use to the browser. The following tags are valid in this
element:

BASE
BASEFONT
BGSOUND
LINK
META
NEXTID
SCRIPT
STYLE
TITLE
The HEAD element requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the HEAD element to create a document title.

<HEAD>
<TITLE>A Simple Document</TITLE>
</HEAD>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
HEAD Element | HEAD Objec... Hn Object DH
Web Workshop | DHTML, HTML & CSS
history Object
Contains information about the URLs visited by the client.

Remarks

For security reasons, the history object does not expose the actual URLs in the
browser history. It does allow navigation through the browser history by exposing the
back, forward, and go methods. A particular document in the browser history can be
identified as an index relative to the current page. For example, specifying -1 as a
parameter for the go method is the equivalent of clicking the Back button.

This object is available in script as of Microsoft® Internet Explorer 3.0.

Members

Applies To

window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
history Object HR Element | HR Object DHTM
Web Workshop | DHTML, HTML & CSS
Hn Element | Hn Object
Renders text in heading style.

Remarks

Use H1 through H6 to specify different sizes and styles of headings.

The Hn element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the H1 element to apply a level-1 heading style to the contained
text.

<H1>Welcome to Internet Explorer!</H1>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Hn Object HTML Element | HTML Objec... DHT
Web Workshop | DHTML, HTML & CSS
HR Element | HR Object
Draws a horizontal rule.

Remarks

The HR element is a block element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
HR Object HTML Comment Element DHTML O
Web Workshop | DHTML, HTML & CSS
HTML Element | HTML Object
Identifies the document as containing HTML elements.

Remarks

By default, the document object is the parent of the HTML element.

The HTML element requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the HTML element to identify the document as an HTML document.

<HTML>
<BODY>
<P>This is an HTML document.</P>
</BODY>
</HTML>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
HTML Comment Element IFRAME Element | IFR
Web Workshop | DHTML, HTML & CSS
I Element | I Object
Specifies that the text should be rendered in italic, where available.

Remarks

The I element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the I element to italicize the text.

<I>This text is italic.</I>

See Also

ADDRESS, CITE, DFN, EM

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
I Element | I Object IMG Element | IMG Object
Web Workshop | DHTML, HTML & CSS
IFRAME Element | IFRAME Object
Creates inline floating frames.

Remarks

The IFRAME element functions as a document within a document, or like a floating


FRAME. The frames collection provides access to the contents of an IFRAME. Use the
frames collection to read or write to elements contained in an IFRAME. For example,
the syntax for accessing the backgroundColor style of the BODY object in an IFRAME
is:

sColor =
document.frames("sFrameName").document.body.style.backgroundColo
r;

You can access the IFRAME object's properties, but not its contents, through the
object model of the page where the IFRAME object resides. For example, the syntax
for accessing the border style of the IFRAME object is:

sBorderValue = document.all.oFrame.style.border;

The IFRAME element is a block element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example uses the IFRAME element and an HTML fragment to create a frame
containing the page sample.htm.

<IFRAME ID=IFrame1 FRAMEBORDER=0 SCROLLING=NO SRC="sample.htm">


</IFRAME>

This example returns a reference to the all collection of the document contained by the
IFRAME.

var collAll = document.frames("IFrame1").document.all

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
IFRAME Element | IFRAME O... INPUT Element
Web Workshop | DHTML, HTML & CSS
IMG Element | IMG Object
Embeds an image or a video clip in the document.

Remarks

This element does not fire the onfocus event when it receives the input focus, unless it
has been associated with a MAP element.

The IMG element is an inline element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the IMG element to embed a bitmap image (.bmp file) on a page.

<IMG SRC=mygraphic.bmp>

See Also

INPUT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
IMG Element | IMG Object INPUT type=button
Web Workshop | DHTML, HTML & CSS
INPUT Element | INPUT Object
Creates a variety of form input controls.

Remarks

The TYPE attribute for the INPUT element is used to specify one of the following form
input controls:

button checkbox file


hidden image password
radio reset submit text

The INPUT element controls are inline elements and do not require a closing tag.

Example

This example uses the INPUT element to create different types of input controls.

<FORM ACTION="http://intranet/survey" METHOD=POST>


<P>Name</P>
<BR><INPUT NAME="CONTROL1" TYPE=TEXT VALUE="Your Name">
<P>Password</P>
<BR><INPUT TYPE="PASSWORD" NAME="CONTROL2">
<P>Color</P>
<BR><INPUT TYPE="RADIO" NAME="CONTROL3" VALUE="0" CHECKED>Red
<INPUT TYPE="RADIO" NAME="CONTROL3" VALUE="1">Green
<INPUT TYPE="RADIO" NAME="CONTROL3" VALUE="2">Blue
<P>Comments</P>
<BR><INPUT TYPE="TEXT" NAME="CONTROL4" SIZE="20,5"
MAXLENGTH="250">
<P><INPUT NAME="CONTROL5" TYPE=CHECKBOX CHECKED>Send receipt</P>
<P><INPUT TYPE="SUBMIT" VALUE="OK"><INPUT TYPE="RESET"
VALUE="Reset"></P>
</FORM>

See Also

BUTTON, SELECT, TEXTAREA

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=text Element |... INSINDEX Eleme
Web Workshop | DHTML, HTML & CSS
INS Element | INS Object
Specifies text that has been inserted into the document.

Remarks

Text contained by the INS element is rendered underlined.

The INS element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example uses the INS element to specify text inserted into a document.

<INS datetime="1997-10-01T12:15:30-05:00">This text has been


inserted.</INS>

See Also

DEL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INS Element | INS Object KBD Element | KBD O
Web Workshop | DHTML, HTML & CSS
ISINDEX Element | ISINDEX Object
Causes the browser to display a dialog window that prompts the user for a single line of
input.

Remarks

In HTML 4, this element is deprecated, and INPUT recommended for use instead. The
tagName property for ISINDEX returns INPUT.

The ISINDEX element belongs in the body of the document.

The ISINDEX element is an inline element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the ISINDEX element to replace the default prompt.

<ISINDEX PROMPT="Enter a keyword to search for in the index">

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ISINDEX Element | ISINDEX... LABEL DHTML
Web Workshop | DHTML, HTML & CSS
KBD Element | KBD Object
Renders text in a fixed-width font.

Remarks

The KBD element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the KBD element to render text in a fixed-width font.

<KBD>This text renders in a fixed-width font.</KBD>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
KBD Element | KBD Object LEGEND Element |
Web Workshop | DHTML, HTML & CSS
LABEL Element | LABEL Object
Specifies a label for another element on the page.

Remarks

To bind LABEL to another control, set the FOR attribute of the LABEL element equal
to the ID of the control. Binding LABEL to the NAME attribute of the control has no
effect. However, to submit a form, you must specify a NAME on the control to which
the LABEL element is being bound.

There are two ways to underline the designated access key. The rich text support in
the LABEL object makes it possible to wrap the U element around the character in the
label text specified by the accessKey property. If you prefer to use cascading style
sheets (CSS) to apply style formatting, enclose the designated character in a SPAN and
set the style to "text-decoration: underline".

If the user clicks the label, the onclick event goes to the label and then bubbles to the
control specified by the htmlFor property. Pressing the access key for the label is the
same as clicking the label.

The LABEL element is an inline element and requires a closing tag. Labels cannot be
nested.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example uses the LABEL object and the accessKey property to set focus on a
text box.

<LABEL FOR="oCtrlID" ACCESSKEY="1">


#<U>1</U>: Press Alt+1 to set focus to textbox
</LABEL>
<INPUT TYPE="text" NAME="TXT1" VALUE="binding sample 1"
SIZE="20" TABINDEX="1" ID="oCtrlID">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
LABEL Element | LABEL Obj... LI Element | LI O
Web Workshop | DHTML, HTML & CSS
LEGEND Element | LEGEND Object
Inserts a caption into the box drawn by the FIELDSET object.

Remarks

This element must be the first element in FIELDSET.

The LEGEND element is a block element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
LEGEND Element | LEGEND O... LINK Element
Web Workshop | DHTML, HTML & CSS
LI Element | LI Object
Denotes one item in a list.

Remarks

The TYPE attribute values disc, circle, and square apply to unordered lists; the
values 1, a, A, i, and I apply to ordered lists.

The LI element is an inline element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the LI element to create individual items in a directory list.

<DIR>
<LI>Art
<LI>History
<LI>Literature
<LI>Sports
<LI>Entertainment
<LI>Science
</DIR>

See Also

DIR, MENU, OL, UL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
LI Element | LI Object LISTING Element | LIST
Web Workshop | DHTML, HTML & CSS
LINK Element | LINK Object
Enables the current document to establish links to external documents.

Remarks

The LINK element can be used only within the HEAD tag.

The LINK element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the LINK element to apply an external style sheet, called
styles.css, to the page.

<LINK REL=stylesheet HREF="styles.css">

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
LINK Element | LINK Objec... location Object
Web Workshop | DHTML, HTML & CSS
LISTING Element | LISTING Object
Renders text in a fixed-width font.

Remarks

This tag is no longer recommended. Use the PRE or SAMP tag instead.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
LISTING Element | LISTING... MAP Element | M
Web Workshop | DHTML, HTML & CSS
location Object
Contains information about the current URL.

Remarks

The href property contains the entire URL, while the other properties contain portions
of the URL. The default property for the location object is location.href. For
example, setting location='http://microsoft.com' is equivalent to setting
location.href='http://microsoft.com'.

The browser immediately navigates to the specified URL when any of the properties
listed below are set.

This object is available in script as of Microsoft® Internet Explorer 3.0.

Members

Applies To

document, window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
location Object MARQUEE Element | MARQUEE.
Web Workshop | DHTML, HTML & CSS
MAP Element | MAP Object
Contains coordinate data for client-side image maps.

Remarks

An image map is a graphic image, with predefined regions, that contains links to other
documents or anchors. For example, you could create an image of the solar system
containing links that the user can click to navigate to pages for the individual planets.

The MAP object is referenced with the USEMAP attribute in an IMG element, as
follows:

<IMG SRC="solarsys.gif" USEMAP="#SystemMap">

A MAP element contains a set of AREA elements defining the linking regions in the
image.

The MAP element requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example provides the full code for an image map of the solar system. It creates
links from the image map to individual images of the planets using the AREA element
with the MAP element, COORDS value, and SHAPE attribute. The user clicks the sun or
any planet to link to an individual image. To return to the solar system image map, the
user clicks the Back button.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
MAP Element | MAP Object MENU Element | ME
Web Workshop | DHTML, HTML & CSS
MARQUEE Element | MARQUEE Object
Creates a scrolling text marquee.

Remarks

The default width of the MARQUEE element is equal to the width of its parent
element. When a MARQUEE is in a TD that does not specify a width, you should
explicitly set the width of MARQUEE. If neither the MARQUEE nor the TD has a width
specified, the marquee is collapsed to a 1-pixel width.

To create a vertically scrolling MARQUEE, set its scrollLeft property to 0. To create a


horizontally scrolling marquee, set its scrollTop property to 0, overriding any script
setting.

The MARQUEE element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the MARQUEE element to scroll the marquee from left to right
across the screen, moving it 10 pixels every 200 milliseconds.

<MARQUEE DIRECTION=RIGHT BEHAVIOR=SCROLL SCROLLAMOUNT=10


SCROLLDELAY=200>
This is a scrolling marquee.
</MARQUEE>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
MARQUEE Element | MARQUEE... META Elemen
Web Workshop | DHTML, HTML & CSS
MENU Element | MENU Object
Creates an unordered list of items.

Remarks

The MENU element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the MENU element to create a menu with two items.

<MENU>
<LI>This is the first item in the menu.
<LI>And this is the second item in the menu.
</MENU>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
.">

MENU Element | MENU Objec... navigator Obje


Web Workshop | DHTML, HTML & CSS
META Element | META Object
Conveys hidden information about the document to the server and the client.

Remarks

The META element also embeds document information that some search engines use
to index and categorize documents on the World Wide Web.

This element can be used only within the HEAD element.

The META element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
META Element | META Objec... NEXTID Object
Web Workshop | DHTML, HTML & CSS
navigator Object
Contains information about the Web browser.

Remarks

This object is available in script as of Microsoft® Internet Explorer 3.0.

Members

Applies To

window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
navigator Object NOBR Element | NOBR Objec.
Web Workshop | DHTML, HTML & CSS
NEXTID Object
Creates unique identifiers that text editing software can read.

Remarks

This element can be used only within the HEAD tag.

The NEXTID element does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
NEXTID Object NOFRAMES Element | NOFRAM.
Web Workshop | DHTML, HTML & CSS
NOBR Element | NOBR Object
Renders text without line breaks.

Remarks

The NOBR element requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example uses the NOBR element to prevent text lines from breaking.

<NOBR>Here's a line of text I don't want to be broken . . .


here's the end of the line.</NOBR>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
NOBR Element | NOBR Objec... NOSCRIPT Elem
Web Workshop | DHTML, HTML & CSS
NOFRAMES Element | NOFRAMES Object
Contains HTML for browsers that do not support FRAMESET elements.

Remarks

The NOFRAMES element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the NOFRAMES element to specify HTML that is rendered by
browsers incapable of displaying frames.

<FRAMESET>
<NOFRAMES>You need Internet Explorer version 3.0 or later to
view
frames!</NOFRAMES>
</FRAMESET>

See Also

FRAME

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
NOFRAMES Element | NOFRAM... OBJECT Elem
Web Workshop | DHTML, HTML & CSS
NOSCRIPT Element | NOSCRIPT Object
Specifies HTML to be displayed in browsers that do not support scripting.

Remarks

The NOSCRIPT element is a block element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
NOSCRIPT Element | NOSCRI... OL Element | O
Web Workshop | DHTML, HTML & CSS
OBJECT Element | OBJECT Object
Inserts an object into the HTML page.

Remarks

An object can appear in the HEAD or the BODY of a document.

Possible return values (those generated by DHTML Object Model properties) on the
OBJECT element depend on the implementation of the OBJECT. For example, the
readyState property returns null or error if the OBJECT does not implement a
readyState property. DHTML Object Model properties available for an OBJECT depend
on the content of the OBJECT. For information about supported properties, see the
documentation for the individual object.

Events are sent directly to the OBJECT element. If the event is returned by the
embedded object, it bubbles accordingly. If the event is not returned, it does not
bubble.

OBJECT event handlers also can be defined in script (see Example).

Note You can use the object property for the OBJECT element to reconcile DHTML
Object Model members that are duplicated by the OBJECT element's implementation
and by DHTML. For instance, if the OBJECT implements an item method, and DHTML
implements an item method, use document.all.objectID.object.item() to access
the one defined for the OBJECT.

The OBJECT element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses script to define event handlers on the OBJECT element.

<SCRIPT FOR=oObject EVENT=eEvent>


:
</SCRIPT>

<OBJECT ID=oObject CLASSID="xyz.abc">


</OBJECT>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
OBJECT Element | OBJECT O... OPTION Elemen
Web Workshop | DHTML, HTML & CSS
OL Element | OL Object
Draws lines of text as a numbered list.

Remarks

The TYPE attribute sets the list type for all ensuing lists unless a different type value is
set.

The OL element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the OL element to create a numbered list.

<OL>
<LI>This is the first item in the list.
<LI>And this is the second item in the list.
</OL>

<OL START=3>
<LI>This is item number 3.
</OL>

<OL TYPE=A>
<LI>This is item A.
</OL>

See Also

LI

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
OL Element | OL Object P Element | P Object
Web Workshop | DHTML, HTML & CSS
OPTION Element | OPTION Object
Denotes one choice in a SELECT element.

Remarks

Although OPTION elements do not appear in the all collection, you can gain access to
these elements by applying the options collection to the SELECT element.

You can add OPTION elements only to a SELECT element located in the same window
where the OPTION elements are created.

Except for background-color and color, style settings applied through the style object
for the OPTION element are ignored. In addition, style settings applied directly to
individual options override those applied to the containing SELECT element as a
whole.

The OPTION element does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the OPTION element to create individual items in a drop-down list
box.

<SELECT ID="oCars" SIZE="1" onchange="fnChange()">


<OPTION VALUE="1">BMW
<OPTION VALUE="2">PORSCHE
<OPTION VALUE="3" SELECTED>MERCEDES
</SELECT>
<TEXTAREA ID="oData"></TEXTAREA>

This example uses the options collection to append the selected item of the list box in
a text area.

<SCRIPT LANGUAGE="JScript">
function fnChange(){
oData.value+=oCars.options[oCars.selectedIndex].text + "\n";
}
</SCRIPT>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
OPTION Element | OPTION O... PARAM Elemen
Web Workshop | DHTML, HTML & CSS
P Element | P Object
Denotes a paragraph.

Remarks

The P element is a block element and does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the P element to create a paragraph.

<P>This is a paragraph.</P>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
P Element | P Object PLAINTEXT Element | PLA
Web Workshop | DHTML, HTML & CSS
PARAM Element | PARAM Object
Sets the property value for a given object.

Remarks

The PARAM element is valid within the APPLET, EMBED, and OBJECT elements.

The PARAM element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0.

Members

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
PARAM Element | PARAM Obj... PRE Element |
Web Workshop | DHTML, HTML & CSS
PLAINTEXT Element | PLAINTEXT Object
Renders text in a fixed-width font without processing tags.

Remarks

This element is no longer recommended.

Members

See Also

XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
PLAINTEXT Element | PLAIN... Q Element | Q O
Web Workshop | DHTML, HTML & CSS
PRE Element | PRE Object
Renders text in a fixed-width font.

Remarks

Text within the PRE element is formatted. Spaces and carriage returns are preserved.

The PRE element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the PRE element to format text so that it renders exactly as it's
typed.

<PRE>
This text is formatted
exactly
as
it
is
typed.
</PRE>

See Also

XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
PRE Element | PRE Object RT Element | RT Obj
Web Workshop | DHTML, HTML & CSS
Q Element | Q Object
Sets apart a quotation in text.

Remarks

The Q element is an inline element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example uses the Q element to set apart a quotation in text.

<P>He said,
<Q>"Hi there!"</Q>

See Also

BLOCKQUOTE

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Q Element | Q Object RUBY Element | RUBY Ob
Web Workshop | DHTML, HTML & CSS
RT Element | RT Object
Designates the ruby text for the RUBY element.

Remarks

A ruby is an annotation or pronunciation guide for a string of text. The string of text
annotated with a ruby is referred to as the base.

The ruby text specified by the RT element is positioned above or inline with the
rubyPosition property. Browsers that do not support the RT element render the ruby
text inline with the base text.

The RT element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the RT element to specify a string of text as an annotation or


pronunciation guide to the base text.

<RUBY>
Base Text
<RT>Ruby Text
</RUBY>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

See Also

RUBY

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
RT Element | RT Object rule Object DHTML O
Web Workshop | DHTML, HTML & CSS
RUBY Element | RUBY Object
Designates an annotation or pronunciation guide to be placed above or inline with a string
of text.

Remarks

A ruby is an annotation or pronunciation guide for a string of text. The string of text
annotated with a ruby is referred to as the base.

The only valid object within the RUBY element is the RT element. Text not contained
within the ruby text object, RT, is assumed to be a part of the base.

The RUBY element is an inline element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the RUBY element to specify the first string of text as the base,
and the RT element to specify the second string of text as the ruby.

<RUBY>
Base Text
<RT>Ruby Text
</RUBY>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

See Also

RT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
RUBY Element | RUBY Objec... runtimeStyle Ob
Web Workshop | DHTML, HTML & CSS
rule Object
Represents a style within a cascading style sheet (CSS) that consists of a selector and one
or more declarations.

Remarks

The rule object defines a set of CSS attributes applied to a set of HTML elements. For
example, a rule consisting of the selector H1 and the declaration font-family:Arial
defines all H1 elements to render in the Arial font.

This object is available in script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses a rule object consisting of the selector H1 to define a single rule
that changes the H1 heading(s) in a document to red.

<STYLE>
H1 { color: red }
</STYLE>

If the style sheet containing the preceding rule is the first style sheet in the document,
the following code returns the rule object associated with the rule.

oRule=document.styleSheets(0).rules(0)

See Also

rules

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
rule Object S Element | S Object DHTML Obje
Web Workshop | DHTML, HTML & CSS
runtimeStyle Object
Represents the cascaded format and style of the object that overrides the format and style
specified in global style sheets, inline styles, and HTML attributes.

Remarks

The runtimeStyle object sets and retrieves the format and style of an object, and
overrides existing formats and styles in the process. Other than having precedence
over the style object and not persisting, the runtimeStyle object is equivalent to the
style object.

Members

Example

This example sets a value on the runtimeStyle object to affect the currentStyle
object, but not the style object.

<SCRIPT>
function fnChangeValue(sValue){
if(oDIV.runtimeStyle.backgroundColor ==
oDIV.style.backgroundColor){
sValue="";
}
oDIV.runtimeStyle.backgroundColor = sValue;
alert(oDIV.style.backgroundColor +
"\n" + oDIV.currentStyle.backgroundColor +
"\n" + oDIV.runtimeStyle.backgroundColor);
}
</SCRIPT>

<DIV ID = "oDIV">
This is a demonstration DIV.
</DIV>

<INPUT TYPE = "button" VALUE = "Change Color"


onclick="fnChangeValue('blue')">

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BGSOUND, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE, CODE,
COL, COLGROUP, COMMENT, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn, HR,
HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, KBD, LABEL, LEGEND, LI, LINK, LISTING, MAP,
MARQUEE, MENU, META, NEXTID, NOBR, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, rule, S, SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE,
STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR, XMP

See Also

currentStyle

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
runtimeStyle Object SAMP Element | SAMP Obj
Web Workshop | DHTML, HTML & CSS
S Element | S Object
Renders text in strike-through type.

Remarks

The S element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the S element to render the text with a line through it.

<S>This text has a line through it.</S>

See Also

STRIKE

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
S Element | S Object screen Object DHTML O
Web Workshop | DHTML, HTML & CSS
SAMP Element | SAMP Object
Specifies a code sample.

Remarks

The SAMP element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the SAMP element to create a code sample.

<SAMP>Here is some text in a small fixed-width font.</SAMP>

See Also

CODE

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SAMP Element | SAMP Objec... SCRIPT Elemen
Web Workshop | DHTML, HTML & CSS
screen Object
Contains information about the client's screen and rendering capabilities.

Remarks

This object is available in script as of Microsoft® Internet Explorer 4.0.

Members

Applies To

window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
screen Object SELECT Element | SELECT O...
Web Workshop | DHTML, HTML & CSS
SCRIPT Element | SCRIPT Object
Specifies a script for the page that is interpreted by a script engine.

Remarks

Code within the SCRIPT block that is not contained within a function is executed
immediately as the page is loaded. To keep scripts from being displayed on down-level
browsers, nest the SCRIPT block within a COMMENT block.

Script appearing after a FRAMESET element is ignored.

The SCRIPT element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

See Also

embedding an xml data island into an html page


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SCRIPT Element | SCRIPT O... selection Object
Web Workshop | DHTML, HTML & CSS
SELECT Element | SELECT Object
Denotes a list box or drop-down list.

Remarks

The SELECT element is an inline element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the SELECT element to create a drop-down list box.

<SELECT NAME="Cats" SIZE="1">


<OPTION VALUE="1">Calico
<OPTION VALUE="2">Tortie
<OPTION VALUE="3" SELECTED>Siamese
</SELECT>

This example uses the SELECT element to create a multi-select list box by setting the
SIZE and MULTIPLE attributes. To retrieve the selected options for a multi-select list
box, iterate through the options collection and check to see where SELECTED is set to
true.

<SELECT NAME="Cars" SIZE="3" MULTIPLE>


<OPTION VALUE="1" SELECTED>BMW
<OPTION VALUE="2">PORSCHE
<OPTION VALUE="3" SELECTED>MERCEDES
</SELECT>

This example adds a new option to the end of an existing SELECT list. The new Option
constructor can also be used in Microsoft® JScript® (compatible with ECMA 262
language specification).

<SCRIPT LANGUAGE="JScript">
var oOption = document.createElement("OPTION");
oOption.text="Apples";
oOption.value="5";
document.all.oMyList.add(oOption);
</SCRIPT>

See Also

OPTION
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SELECT Element | SELECT O... SMALL Element
Web Workshop | DHTML, HTML & CSS
selection Object
Represents the active selection, which is a highlighted block of text, and/or other elements
in the document on which a user or a script can carry out some action.

Remarks

You typically use the selection object as input from the user to identify which portion
of the document to act on, or as output to the user to show the results of an action.

Users and scripts can create selections. Users create selections by dragging the mouse
over a portion of the document. Scripts create selections by calling the select method
on a text range or similar object. To retrieve the active selection, apply the selection
keyword to the document object. To carry out work on a selection, create a text range
object from the selection using the createRange method.

A document can have only one selection at a time. The selection has a type that
determines whether it is empty or contains a block of text and/or elements. Although
an empty selection contains nothing, you can use it to mark a position in the
document.

This object is available in script as of Microsoft® Internet Explorer 4.0.

Members

Applies To

document

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
selection Object SPAN Element | SPAN Objec...
Web Workshop | DHTML, HTML & CSS
SMALL Element | SMALL Object
Specifies that the enclosed text should be displayed in a smaller font.

Remarks

The SMALL element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the SMALL element to display text in a smaller font.

<SMALL>This text is smaller</SMALL> than this text.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SMALL Element | SMALL Obj... STRIKE Element
Web Workshop | DHTML, HTML & CSS
SPAN Element | SPAN Object
Specifies an inline text container.

Remarks

This element is especially useful for applying cascading style sheets (CSS) styles.

The SPAN element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the SPAN element to create an inline text container that changes
the color of a word to blue.

<P>This paragraph contains a single <SPAN STYLE="color:


blue">blue</SPAN> word.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SPAN Element | SPAN Objec... STRONG Elemen
Web Workshop | DHTML, HTML & CSS
STRIKE Element | STRIKE Object
Renders text in strike-through type.

Remarks

The STRIKE element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the STRIKE element to create strike-through type.

<STRIKE>This text has a line through it.</STRIKE>

See Also

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
STRIKE Element | STRIKE O... STYLE Element
Web Workshop | DHTML, HTML & CSS
STRONG Element | STRONG Object
Renders text in bold.

Remarks

The STRONG element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the STRONG element to emphasize text in boldface type.

<STRONG>This text is strongly emphasized (shown as bold).


</STRONG>

See Also

ACRONYM, ADDRESS, B, CITE

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
STYLE Element | STYLE Obj... styleSheet Objec
Web Workshop | DHTML, HTML & CSS
style Object
Represents the current settings of all possible inline styles for a given element.

Remarks

Inline styles are cascading style sheets (CSS) style assignments that you apply directly
to individual HTML elements using the STYLE= attribute. Use the style object to
examine these assignments and to make new assignments or change existing ones.

To retrieve the style object, apply the style keyword to an element object. To
retrieve the current setting for an inline style, apply the corresponding style property
to the style object.

The style object does not provide access to the style assignments in style sheets. To
obtain information about styles in style sheets, use the styleSheets collection to access
to the individual style sheets defined in the document.

The following properties are not available when the rule object accesses the style
object: posHeight, posWidth, posTop, posLeft, pixelHeight, pixelWidth, pixelTop, and
pixelLeft.

This object is available in script in Internet Explorer 4.0.

Members

Example

This example uses the style object to set the document body text font to Verdana.

document.body.style.fontFamily = "Verdana"

This example positions all absolutely positioned images in the given document at the
top of the document.

var oImages = document.all.tags("IMG");


if (oImages.length) {
for (var iImg = 0; iImg < oImages.length; iImg++) {
var oImg = oImages(iImg);
if (oImg.style.position == "absolute") {
oImg.style.top = 0;
}
}
}

This example copies the inline style of the second element (div2) to the first (div1)
while preserving the styles of the second. The background color of div1 is overwritten
during the assignment.

<DIV ID="div1" STYLE="background-color:blue;font-


weight:bold">Item 1</DIV>
<DIV ID="div2" STYLE="background-color:red;font-size:18pt;
font-family:Verdana;">Item 2</DIV>

<SCRIPT>
div1.style.cssText += (';' + div2.style.cssText);
</SCRIPT>

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BGSOUND, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE, CODE,
COL, COLGROUP, COMMENT, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn, HR,
HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, KBD, LABEL, LEGEND, LI, LINK, LISTING, MAP,
MARQUEE, MENU, META, NEXTID, NOBR, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, rule, S, SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE,
STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
STRONG Element | STRONG O... style Object
Web Workshop | DHTML, HTML & CSS
STYLE Element | style Object
Specifies a style sheet for the page.

Remarks

The STYLE element should appear in the HEAD section of an HTML document.
Microsoft® Internet Explorer 4.0 and later permit multiple style blocks.

The STYLE element is a block element and requires a closing tag.

This element is available in HTML as of Internet Explorer 3.0, and in script as of


Internet Explorer 4.0.

Members

Example

This example encloses style declarations in the STYLE tag and changes one of those
settings using the style object.

<HEAD>
<STYLE>
BODY { background-color: white; color: black; }
H1 { font: 8pt Arial bold; }
P { font: 10pt Arial; text-indent: 0.5in; }
A { text-decoration: none; color: blue; }
</STYLE>
<SCRIPT>
oParagraph.style.fontSize = 14;
</SCRIPT>
</HEAD>
<BODY>
<P>Sample Paragraph Text</P>
</BODY>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
style Object SUB Element | SUB Object DHTM
Web Workshop | DHTML, HTML & CSS
styleSheet Object
Represents a single style sheet in the document.

Remarks

You can use this object to retrieve style sheet information, such as the URL of the
source file for the style sheet and the element in the document that owns (defines) the
style sheet. You also can use it to modify style sheets.

You can retrieve a styleSheet object from the styleSheets collection or from the
imports collection. Each item in these collections is a style sheet. A styleSheet object
is available for a style sheet only if it is included in a document with a STYLE or LINK
element, or with an @import statement in a STYLE element.

This object is available in script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example uses the styleSheet object to change the cascading style sheets (CSS)
values of inline and imported styles.

<STYLE>
BODY {background-color: #CFCFCF;}
@import url("otherStyleSheet.css");
</STYLE>
<SCRIPT>
window.onload=fnInit;
function fnInit(){
// Access a rule in the styleSheet, change backgroundColor to
blue.
var oStyleSheet=document.styleSheets[0];
var oRule=oStyleSheet.rules[0];
oRule.backgroundColor="#0000FF";
// Add a rule for P elements to have yellow backgrounds.
oStyleSheet.addRule("P","background-color: #FFFF00;");
// Change and imported rule:
oStyleSheet.imports[0].color="#000000";
}
</SCRIPT>

Applies To

styleSheets
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
styleSheet Object SUP Element | SUP Object
Web Workshop | DHTML, HTML & CSS
SUB Element | SUB Object
Specifies that the enclosed text should be displayed in subscript, using a smaller font than
the current font.

Remarks

The SUB element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the SUB element to change some of the text to a subscript font.

(X<SUB>1</SUB>,Y<SUB>1</SUB>)

The preceding code causes the text to render as follows:


(X1,Y1)

See Also

SUP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SUB Element | SUB Object TABLE Element | TA
Web Workshop | DHTML, HTML & CSS
SUP Element | SUP Object
Specifies that the enclosed text should be displayed in superscript, using a smaller font
than the current font.

Remarks

The SUP element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the SUP element to change some of the text to a superscript font.

(X<SUP>2</SUP> + Y<SUP>2</SUP>)

The preceding code causes the text to render as follows:


(X2 + Y2)

See Also

SUB

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SUP Element | SUP Object TBODY Element | TB
Web Workshop | DHTML, HTML & CSS
TABLE Element | TABLE Object
Specifies that the contained content is organized into a table with rows and columns.

Remarks

The following tags are valid within a table: CAPTION, COL, COLGROUP, TBODY, TD,
TFOOT, TH, THEAD, and TR.

While a document loads, modifications to a table are restricted until the


window.onload event occurs. Read-only access is allowed at any time.

The TABLE object model is read-only for databound tables. For example, script used
to remove a table row works correctly on an unbound table, but not on a databound
table. The properties of a table object are still available, but changes to the bound
data in a table must be made to the data source.

The properties of a table are distinct from the properties of cells contained within the
table. For example, the offsetLeft property of a multicolumn table is not the same as
the offsetLeft property of the left-most cell in the table. Refer to the appropriate
object when writing scripts involving table and/or cell objects.

The TABLE element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the TABLE element with THEAD, TR, and TH to create a table with
three rows and two columns.

<TABLE BORDER=1 WIDTH=80%>


<THEAD>
<TR>
<TH>Heading 1</TH>
<TH>Heading 2</TH>
</TR>
</THEAD>
<TBODY>
<TR>
<TD>Row 1, Column 1 text.</TD>
<TD>Row 1, Column 2 text.</TD>
</TR>
<TR>
<TD>Row 2, Column 1 text.</TD>
<TD>Row 2, Column 2 text.</TD>
</TR>
</TBODY>
</TABLE>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TABLE Element | TABLE Obj... TD Element | TD
Web Workshop | DHTML, HTML & CSS
TBODY Element | TBODY Object
Designates rows as the body of the table.

Remarks

Valid tags within the TBODY element include:

TD
TH
TR
This element is exposed for all tables, even if the table does not explicitly define a
TBODY element.

The TBODY element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the TBODY element with the TABLE, TD, THEAD, and TR objects to
create a table with the first row in the table head and the second row in the table
body.

<TABLE>
<THEAD>
<TR>
<TD>
This text is in the THEAD.
</TD>
</TR>
</THEAD>
<TBODY>
<TR>
<TD>
This text is in the TBODY.
</TD>
</TR>
</TBODY>
</TABLE>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TBODY Element | TBODY Obj... TEXTAREA Elem
Web Workshop | DHTML, HTML & CSS
TD Element | TD Object
Specifies a cell in a table.

Remarks

The TD element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

See Also

TABLE, TH, TR, borderCollapse

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TD Element | TD Object TextNode Object DHT
Web Workshop | DHTML, HTML & CSS
TEXTAREA Element | TEXTAREA Object
Specifies a multiline text input control.

Remarks

The default font is fixed pitch.

The TEXTAREA element is an inline element and requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the TEXTAREA element to set the cascading style sheets (CSS)
overflow attribute to "hidden" to remove the scroll bars from the TEXTAREA.

<TEXTAREA STYLE="overflow:hidden" ID=txtComments>


The patient is in stable condition after suffering an attack
of
the insatiable munchies.
</TEXTAREA>

See Also

INPUT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TEXTAREA Element | TEXTAR... TextRange Obje
Web Workshop | DHTML, HTML & CSS
TextNode Object
Represents a string of text as a node in the document hierarchy.

Remarks

Use the createTextNode method to create a TextNode object. Once you create the
TextNode, you can add to it using the appendChild, replaceNode, or insertBefore
methods.

This object is available in script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the TextNode object to change the text of an LI object.

<SCRIPT>
function fnChangeText(){
var oTextNode = document.createTextNode("New List Item 1");
var oReplaceNode = oItem1.firstChild.replaceNode(oTextNode);
}
</SCRIPT>

<UL onclick = "fnChangeText()">


<LI ID = oItem1>List Item 1
</UL>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TextNode Object TextRectangle Object DHTML
Web Workshop | DHTML, HTML & CSS
TextRange Object
Represents text in an HTML element.

Remarks

Use this object to retrieve and modify text in an element, to locate specific strings in
the text, and to carry out commands that affect the appearance of the text.

To retrieve a text range object, apply the createTextRange method to a BODY,


BUTTON, or TEXTAREA element or an INPUT element that has text type.

Modify the extent of the text range by moving its start and end positions with methods
such as move, moveToElementText, and findText. Within the text range, you can
retrieve and modify plain text or HTML text. These forms of text are identical except
that HTML text includes HTML tags, and plain text does not.

This feature might not be available on non-Win32® platforms. See article q172976
I
in the Microsoft® Knowledge Base for the latest information on Internet Explorer
cross-platform compatibility.

This object is available in script as of Microsoft® Internet Explorer 4.0.

Members

Example

This example changes the text of a BUTTON element to "Clicked" through the
TextRange object.

<SCRIPT LANGUAGE="JScript">
var b = document.all.tags("BUTTON");
if (b!=null) {
var r = b[0].createTextRange();
if (r != null) {
r.text = "Clicked";
}
}
</SCRIPT>

See Also

createTextRange

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TextRange Object TFOOT Element | TFOOT Obj
Web Workshop | DHTML, HTML & CSS
TextRectangle Object
Specifies a rectangle that contains a line of text in either an element or a TextRange
object.

Remarks

Apply the getClientRects method to an element or text range object to retrieve a


collection of TextRectangle objects. The getClientRects method returns a collection
of rectangles, exposing for each rectangle the left, top, right, and bottom coordinates
relative to the client.

In the following excerpt from the Gettysburg Address, four TextRectangle objects are
contained in the B element (bold text).

Four score and seven years ago our fathers


brought forth . . . a new nation, conceived in liberty
and dedicated to the proposition that all men are
created equal. Now we are engaged in a great civil war . . .

The four TextRectangle objects are:

1. "our fathers"
2. "brought forth . . . a new nation, conceived in liberty"
3. "and dedicated to the proposition that all men are"
4. "created equal"

If you resize the window containing this text, the TextRectangle objects do not
update. Since the objects are a snapshot of the layout, the objects should update
following after an onresize event occurs.

This object is available in script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the getClientRects and getBoundingClientRect methods to


highlight text lines in an object.

This example uses the TextRectangle collection with the getClientRects and
getBoundingClientRect methods to determine the position of the text rectangle
within an element. In each line, the left-justified text does not extend to the right
margin of the box that contains the text. Using this collection, you can determine the
coordinates of the rectangle that surrounds only the content in each line. The example
code reads these rectangle coordinates and instructs the ball to move over the text
only, and not to the end of the line.
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TextRectangle Object TH Element | TH Object
Web Workshop | DHTML, HTML & CSS
TFOOT Element | TFOOT Object
Designates rows as the table's footer.

Remarks

Valid tags within the TFOOT element include:

TD
TH
TR
The TFOOT element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the TFOOT element with the TABLE, TBODY, TD, and TR objects to
create a table with the first row in the table body and the second row in the table
footer.

<TABLE>
<TBODY>
<TR>
<TD>
This text is in the table body.
</TD>
</TR>
</TBODY>
<TFOOT>
<TR>
<TD>
This text is in the table footer.
</TD>
</TR>
</TFOOT>
</TABLE>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TFOOT Element | TFOOT Obj... THEAD Element
Web Workshop | DHTML, HTML & CSS
TH Element | TH Object
Specifies a header column. Header columns are centered within the cell and are bold.

Remarks

The TH element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

See Also

TD, TR

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TH Element | TH Object TITLE Element | TITLE
Web Workshop | DHTML, HTML & CSS
THEAD Element | THEAD Object
Designates rows as the table's header.

Remarks

Valid tags within the THEAD element include:

TD
TH
TR
The THEAD element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the TFOOT element with the TABLE, TBODY, TD, and TR objects to
create a table with the first row in the table header and the second row in the table
body.

<TABLE>
<THEAD>
<TR>
<TD>
This text is in the table header.
</TD>
</TR>
</THEAD>
<TBODY>
<TR>
<TD>
This text is in the table body.
</TD>
</TR>
</TBODY>
</TABLE>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
THEAD Element | THEAD Obj... TR Element | T
Web Workshop | DHTML, HTML & CSS
TITLE Element | title Object
Contains the title of the document.

Remarks

This element can be used only within the HEAD element. Any text between the opening
and closing TITLE tags displays in the browser title bar and in the Microsoft®
Windows® taskbar. In Web pages, "Microsoft Internet Explorer" is appended to the
title. In HTML Applications, by contrast, only the specified title appears.

The TITLE element is a block element and requires a closing tag.

This element is available in HTML as of Internet Explorer 3.0, and in script as of


Internet Explorer 4.0.

Members

Example

This example uses the TITLE element to specify a title for the document.

<HEAD>
<TITLE>"Welcome to Internet Explorer!"</TITLE>
</HEAD>

Applies To

document

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TITLE Element | TITLE Obj... TT Element | TT O
Web Workshop | DHTML, HTML & CSS
TR Element | TR Object
Specifies a row in a table.

Remarks

The TD and TH tags are valid within a row.

The TR element does not explicitly support the HEIGHT attribute. To achieve the same
effect, use the cascading style sheets (CSS) height attribute.

To change the HTML in the TR element, use the table object model. For example, use
the rowIndex property or the rows collection to retrieve a reference to a specific table
row. You can add or delete rows using the insertRow and deleteRow methods. To
retrieve a reference to a specific cell, use the cellIndex property or the cells collection.
You can add or delete rows using the insertCell and deleteCell methods. To change the
content of a particular cell, use the innerHTML or innerText property.

The TR element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

The following examples show how to create a table row in HTML and script.

See Also

TABLE, borderCollapse

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TR Element | TR Object U Element | U Object
Web Workshop | DHTML, HTML & CSS
TT Element | TT Object
Renders text in a fixed-width font.

Remarks

The TT element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the TT element to render text in a fix-width font.

<TT>Here's some plain text.</TT>

See Also

XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TT Element | TT Object UL Element | UL Object
Web Workshop | DHTML, HTML & CSS
U Element | U Object
Renders text that is underlined.

Remarks

The U element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the U element to underline text.

<U>This text is underlined.</U>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
U Element | U Object userProfile Object DHTM
Web Workshop | DHTML, HTML & CSS
UL Element | UL Object
Draws lines of text as a bulleted list.

Remarks

The TYPE attribute sets the list type for all ensuing lists unless a different type value is
set.

The UL element inherits its line-height from the height of the font attribute for the
BODY. For example, if the font-size attribute for the BODY is larger than the font-size
attribute for the UL element, the list items in the UL are spaced according to the font-
size of the BODY.

The UL element is a block element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the UL element to create a bulleted list.

<UL>
<LI>This is the first bulleted item in the list.
<LI>And this is the second bulleted item in the list.
</UL>

See Also

LI

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
UL Element | UL Object VAR Element | VAR Obj
Web Workshop | DHTML, HTML & CSS
userProfile Object
Provides methods that allow a script to request read access to and perform read actions on
a user's profile information.

Remarks

The script request is queued before reading or writing is performed. This simplifies
user experience, because users are prompted only once for profile release permissions
for a batch of requests.

This object is available in script as of Microsoft® Internet Explorer 4.0.

Members

Example

This script example runs on the client and uses the userProfile object to read various
values from the profile information.

// Queue a request for read access to multiple profile


attributes.
navigator.userProfile.addReadRequest("vcard.displayname");
navigator.userProfile.addReadRequest("vcard.gender");

// Request access to the information.


navigator.userProfile.doReadRequest(usage-code, "Acme
Corporation");

// Now perform read operations to access the information.


name = navigator.userProfile.getAttribute("vcard.displayname");
gender = navigator.userProfile.getAttribute("vcard.gender");

// The script can now use the 'name' and 'gender' variables
// to personalize content or to send information back to the
server.

// Clear the request queue to prepare for future information


requests.
navigator.userProfile.clearRequest();

Applies To

clientInformation, navigator

See Also

profile assistantI
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
userProfile Object WBR Element | WBR Object
Web Workshop | DHTML, HTML & CSS
VAR Element | VAR Object
Renders text in a small fixed-width font.

Remarks

The VAR element is an inline element and requires a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the VAR element to render the word "filename" in a small fixed-
width font.

Enter the <VAR>filename</VAR> in the dialog box.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
VAR Element | VAR Object window Object DH
Web Workshop | DHTML, HTML & CSS
WBR Element | WBR Object
Inserts a soft line break into a block of NOBR text.

Remarks

The WBR element does not require a closing tag.

This element is available in HTML as of Microsoft® Internet Explorer 3.0, and in script
as of Internet Explorer 4.0.

Members

Example

This example uses the WBR element to create line breaks. In contrast, the NOBR
element does not break lines.

<NOBR>This line of text will not break, no matter how narrow the
window gets.</NOBR>
<NOBR>This one, however,<WBR> will break after the word
"however,"
if the window gets small enough.</NOBR>

See Also

BR

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
WBR Element | WBR Object XML Element | XML
Web Workshop | DHTML, HTML & CSS
window Object
Represents an open window in the browser.

Remarks

You can use the window object to retrieve information about the state of the window.
You also can use this object to gain access to the document in the window, to the
events that occur in the window, and to features of the browser that affect the window.

Typically, the browser creates one window object when it opens an HTML document.
However, if a document defines one or more frames (that is, contains one or more
FRAME or IFRAME tags), the browser creates one window object for the original
document and one additional window object for each frame. These additional objects
are child windows of the original window and can be affected by actions that occur in
the original. For example, closing the original window causes all child windows to close.
You can also create new windows (and corresponding window objects) using methods
such as open, showModalDialog, and showModelessDialog.

You can apply any window property, method, or collection to any variable or expression
that evaluates to a window object, regardless of how that window was created.
Additionally, you can access all window properties, methods, and collections in the
current window by using the property, method, or collection name directly—that is,
without prefixing it with an expression that evaluates to the current window object.
However, to help make more readable code and to avoid potential ambiguities, many
authors use the window keyword when accessing window properties, methods, and
collections for the current window. This keyword always refers to the current window.

Note Window property, method, and collection names are reserved keywords and
cannot be used as the names of variables and routines.

The dialogArguments, dialogHeight, dialogLeft, dialogTop, dialogWidth, and


returnValue properties are available only for windows created using the
showModalDialog and showModelessDialog methods.

This object is available in script as of Microsoft® Internet Explorer 3.0.

Windows CE

In Microsoft® Windows® CE, the document object is not available through scripting for
a window opened using the open method.

Members

Example

This example displays an alert for the current window.


alert("A simple message.")

This example checks whether the current window contains child windows and, if it
does, displays the names of those child windows.

if ( window.frames != null ) {
for ( i = 0; i< window.frames.length; i++ )
window.alert ("Child window " +i+ " is named
"+window.frames(i).name);
}

This example shows a simple event handler function for the window's onload event. In
the absence of a "window" element, the BODY element hosts the following window
object events: onblur, onbeforeunload, onfocus, onload, and onunload.

<BODY onload="window.status='Page is loaded!'">

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
window Object XMP Element | XMP Object DH
Web Workshop | DHTML, HTML & CSS
XML Element | XML Object
Defines an xml data island on an HTML page.
I
Remarks

The readyState property of the XML element, available as a string value, corresponds
to the readystate property of the xmldomdocument object, which is available as a
I I
long value. The string values correspond to the long values of the XML document
object's property as follows:

0 uninitialized
1 loading
2 loaded
3 interactive
4 complete

Consider the following XML data island:

<XML ID=xmldoc SRC="123.xml"></XML>

Use the following two methods to check the value of the readyState property to
determine whether the XML data island is completely downloaded.

This method uses the readyState property of the XML element:

if (xmldoc.readyState == "complete")
window.alert ("The XML document is ready.");

This method uses the readystateI property of the XMLDOMDocument object:

if (xmldoc.XMLDocument.readyState == 4)
window.alert ("The XML document is ready.");

The XML element requires a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 5.

Members

Example

This example uses the XML element to define a simple XML data island that can be
embedded directly into an HTML page.

<XML ID="oMetaData">
<METADATA>
<AUTHOR>John Smith</AUTHOR>
<GENERATOR>Visual Notepad</GENERATOR>
<PAGETYPE>Reference</PAGETYPE>
<ABSTRACT>Specifies a data island</ABSTRACT>
</METADATA>
</XML>

This script example retrieves the text contained within the ABSTRACT field of the data
island.

var oNode =
oMetaData.XMLDocument.selectSingleNode("METADATA/ABSTRACT");
alert(oNode.text);

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
XML Element | XML Object DHTML Objects
Web Workshop | DHTML, HTML & CSS
XMP Element | XMP Object
Renders text used for examples in a fixed-width font.

Remarks

Use of this element is no longer recommended. Use the PRE or SAMP element
instead.

Members

See Also

TT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT Element | INPUT Obj... INPUT type=che
Web Workshop | DHTML, HTML & CSS
INPUT type=button Element | INPUT type=button Object
Creates a button control.

Remarks

The button element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the button element to define a button that responds appropriately
when clicked.

<INPUT TYPE=button ID=btnEmergency VALUE="In case of emergency,


push this button!"
onClick="alert('Aaaaaaaggggghh!!!!')">

The preceding HTML code creates this button:

In case of emergency, push this button!

See Also

BUTTON, INPUT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=button Element... INPUT type=file
Web Workshop | DHTML, HTML & CSS
INPUT type=checkbox Element | INPUT type=checkbox Object
Creates a check box control.

Remarks

When a checkbox element is selected, a name/value pair is submitted with the FORM.
The default value of checkbox is on.

The height and width styles are exposed to the checkbox element as of Microsoft®
Internet Explorer 5. The size of the element is set based on the values provided by the
author, except when a given size is below a particular minimum. The size is calculated
as follows:

If the height or width is greater than 20 pixels, the padding around the check
box is set to 4 pixels, and the inner height or width is set to 8 pixels.
If the height or width is less than 20 pixels but greater than 13 pixels, the
padding around the check box is equal to one half the specified height or width
minus 13. For example, if the specified width of the check box is 17, the
equation would be: (17-13)/2.
If the height or width is less than 12 pixels, the padding around the check box
is set to 0 and the inner width is set to the value specified by the author.

The checkbox element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Internet Explorer 3.0.

Members

Example

This example uses the checkbox element to create two check boxes with explanatory
text. The onclick events call two script functions. The first check box is checked.

<INPUT TYPE=checkbox CHECKED ID=chk1


onclick="choosebox1()">Uncheck
this check box for some free advice.
<P><INPUT TYPE=checkbox ID=chk2 onclick="choosebox2()">Or check
this check box for a message from our sponsors.
<P ID=SampText>

This example implements the script when the user clicks either check box.

<SCRIPT>
function choosebox1(){
alert("Never play leapfrog with a unicorn!")
}
function choosebox2(){
SampText.insertAdjacentHTML("AfterBegin","Buy
WonderWidgets! ");
}
</SCRIPT>

The preceding HTML code and script examples create and implement the following
check boxes:

Uncheck this check box for some free advice.


Or check this check box for a message from our sponsors.

See Also

INPUT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=checkbox Eleme... INPUT type=hid
Web Workshop | DHTML, HTML & CSS
INPUT type=file Element | INPUT type=file Object
Creates a file upload object with a text box and Browse button.

Remarks

For a file upload to take place:

The file element must be enclosed within a FORM element.


A value must be specified for the NAME attribute of the file element.
The METHOD attribute of the FORM element must be set to post.
The ENCTYPE attribute of the FORM element must be set to multipart/form-
data.

To handle a file upload to the server, a server-side process must be running that can
handle multipart/form-data submissions. For example, the microsoft posting acceptor
I
allows Microsoft® Internet Information Server to accept file uploads. Additional
Common Gateway Interface (CGI) scripts that can handle multipart/form-data
submissions are available on the Web.

The file element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 4.0.
The file upload add-on is required to use the file element in Internet Explorer 3.02.
Users can enter a file path in the text box or click the Browse button to browse the file
system.

Members

Example

The following examples use the file element to upload a file to a server. The first
example requires Microsoft® Posting Acceptor, which can be used with Internet
Information Server (IIS) or Personal Web Server.

See Also

INPUT, upload files to the internet information server , uploading a file to iis using a
I
browser
I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=file Element |... INPUT type=imag
Web Workshop | DHTML, HTML & CSS
INPUT type=hidden Element | INPUT type=hidden Object
Transmits state information about client/server interaction.

Remarks

This input type presents no control to the user, but sends the value of the value
property with the submitted form.

The hidden element does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

See Also

INPUT, INPUT type=submit

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=hidden Element... INPUT type=pas
Web Workshop | DHTML, HTML & CSS
INPUT type=image Element | INPUT type=image Object
Creates an image control that, when clicked, causes the form to be immediately
submitted.

Remarks

The x-coordinate is submitted under the name of the control with .x appended, and the
y-coordinate is submitted under the name of the control with .y appended. Any value
property is ignored. The src property specifies the image element the same way it
specifies the IMG element.

The image element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

See Also

IMG, INPUT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=image INPUT type=radio DHTML
Web Workshop | DHTML, HTML & CSS
INPUT type=password Element | INPUT type=password Object
Creates a single-line text entry control similar to the text control, except that text is not
displayed as the user enters it.

Remarks

The password element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the password element to define a password field.

Username <INPUT TYPE=button ID=txtUser>


Password <INPUT TYPE=password ID=txtPassword>

This example uses script to determine whether the password is valid for the specified
user.

<SCRIPT>
if (txtUser.value == "Paul")
if (txtPassword.value == "2ifbysea")
{
alert("Password accepted. Enjoy your ride.");
return true;
}
</SCRIPT>

See Also

INPUT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=password INPUT type=submit D
Web Workshop | DHTML, HTML & CSS
INPUT type=radio Element | INPUT type=radio Object
Creates a radio button control.

Remarks

Use a radio button control to limit a user's selection to a single value within a set of
values. To do this, you must link together each button in a set of radio buttons by
assigning each button the same name.

When a user submits a form, a selected radio button only generates a name/value
pair in the form data if the button has a value.

To select a radio button as the default button in a set, set the checked property of the
button to true.

A user can select a radio button only if the button has a name. To clear a selected
radio button, a user must select another button in the set.

The radio element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the radio element to create three radio buttons.

<INPUT type=radio name="radio" CHECKED>1-10 years old


<INPUT type=radio name="radio">11 years old
<INPUT type=radio name="radio">12-120 years old

This example uses script to detect which radio button the user selects.

<SCRIPT>
function detect()
{
if (radio[0].checked)
alert("You're between 1 and 10 years old.")
else if (radio[1].checked)
alert("You're 11 years old.")
else
alert("You're between 12 and 120 years old.")
}
</SCRIPT>
The preceding HTML code and script examples create and implement the following
radio buttons.

1-10 years old

11 years old

12-120 years old

How old are you?

See Also

INPUT, forms overview


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=radio INPUT type=submit DHTM
Web Workshop | DHTML, HTML & CSS
INPUT type=reset Element | INPUT type=reset Object
Creates a button that, when clicked, resets the form's controls to their initial values.

Remarks

The value property specifies the label displayed on the Reset button the same way it
specifies it on the Submit button.

The reset element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

See Also

BUTTON, INPUT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=reset INPUT type=text DHTML O
Web Workshop | DHTML, HTML & CSS
INPUT type=submit Element | INPUT type=submit Object
Creates a button that, when clicked, submits the form.

Remarks

Use the value attribute to create a button with a display label that cannot be edited by
the user. The default label is application-specific. If the user clicks the Submit button to
submit the form, and that button has a name attribute specified, that button
contributes a name/value pair to the submitted data.

The submit element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

See Also

BUTTON, INPUT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
INPUT type=submit INS Element | INS Object
Web Workshop | DHTML, HTML & CSS
INPUT type=text Element | INPUT type=text Object
Creates a single-line text entry control.

Remarks

The SIZE attribute sets the number of visible characters in the text element. The
MAXLENGTH attribute sets the maximum number of characters that can be entered.

The text element is an inline element and does not require a closing tag.

This element is available in HTML and script as of Microsoft® Internet Explorer 3.0.

Members

Example

This example uses the text element to create an empty text control that can contain
15 characters without requiring the user to scroll to read all of the text.

<INPUT TYPE=text VALUE="" NAME="textbox" SIZE=15>

This example uses script to detect the content of the text box and display it in a dialog
box.

<SCRIPT>
function detectEntry()
{
alert("Your name is " + textbox.value)
}
</SCRIPT>

The preceding HTML code and script examples implement the following text box. Click
the What Is Your Name? button to call the detectEntry() function.

Enter your name:

What Is Your Name?

See Also

INPUT, TEXTAREA

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
!important Declaration DHTML References
Web Workshop | DHTML, HTML & CSS
DHTML Properties
The following table lists the properties in the Dynamic HTML Object Model. For
properties that appear in multiple table cells, roll the mouse over the text to view a
ToolTip indicating the objects to which the property applies. Click the text to jump to
a full description of that property.

!important @charset @font-face


@import @media accessKey
action activeElement align
align align align
aLink aLinkColor alt
altHTML altKey appCodeName
appMinorVersion appName appVersion
autocomplete availHeight availWidth
background background background
backgroundAttachment backgroundColor backgroundImage
backgroundPosition backgroundPositionX backgroundPositionY
backgroundRepeat balance behavior
behavior bgColor bgProperties
border border border
borderBottom borderBottomColor borderBottomStyle
borderBottomWidth borderCollapse borderColor
borderColor borderColorDark borderColorLight
borderLeft borderLeftColor borderLeftStyle
borderLeftWidth borderRight borderRightColor
borderRightStyle borderRightWidth borderStyle
borderTop borderTopColor borderTopStyle
borderTopWidth borderWidth bottom
bottom bottomMargin boundingHeight
boundingLeft boundingTop boundingWidth
browserLanguage bufferDepth button
cancelBubble canHaveChildren caption
cellIndex cellPadding cellSpacing
checked classid className
clear clear clientHeight
clientLeft clientTop clientWidth
clientX clientY clip
clipBottom clipLeft clipRight
clipTop closed code
codeBase codeType color
color colorDepth cols
cols cols colSpan
compact complete content
cookie cookieEnabled coords
cpuClass cssText ctrlKey
cursor data data
dataFld dataFld dataFormatAs
dataPageSize dataSrc defaultCharset
defaultChecked defaultSelected defaultStatus
defaultValue defer designMode
dialogArguments dialogHeight dialogLeft
dialogTop dialogWidth dir
direction direction disabled
disabled display documentElement
domain dropEffect dynsrc
effectAllowed encoding event
expando face fgColor
fileCreatedDate fileModifiedDate fileSize
fileUpdatedDate filter firstChild
font fontFamily fontSize
fontSmoothingEnabled fontStyle fontVariant
fontWeight form frame
frameBorder frameSpacing fromElement
hash height height
height hidden host
hostname href href
href href hspace
htmlFor htmlFor htmlText
httpEquiv id imeMode
indeterminate index innerHTML
innerText isMap isTextEdit
keyCode lang language
lastChild lastModified layoutGrid
layoutGridChar layoutGridCharSpacing layoutGridLine
layoutGridMode layoutGridType left
left leftMargin length
length letterSpacing lineBreak
lineHeight link linkColor
listStyle listStyleImage listStylePosition
listStyleType loop loop
lowsrc margin marginBottom
marginHeight marginLeft marginRight
marginTop marginWidth maxLength
media menuArguments method
Methods multiple name
name name nameProp
nextSibling nodeName nodeType
nodeValue noHref noResize
noShade noWrap object
offscreenBuffering offsetHeight offsetLeft
offsetParent offsetTop offsetWidth
offsetX offsetY onLine
opener outerHTML outerText
overflow overflowX overflowY
owningElement padding paddingBottom
paddingLeft paddingRight paddingTop
pageBreakAfter pageBreakBefore palette
parent parentElement parentNode
parentStyleSheet parentTextEdit parentWindow
pathname pixelBottom pixelHeight
pixelLeft pixelRight pixelTop
pixelWidth platform pluginspage
port posBottom posHeight
position posLeft posRight
posTop posWidth previousSibling
propertyName protocol qualifier
readOnly readOnly readyState
reason recordNumber recordset
referrer rel repeat
returnValue returnValue rev
right right rightMargin
rowIndex rows rows
rowSpan rubyAlign rubyOverhang
rubyPosition rules scopeName
screenLeft screenTop screenX
screenY scroll scrollAmount
scrollDelay scrollHeight scrolling
scrollLeft scrollTop scrollWidth
search sectionRowIndex selected
selectedIndex selectorText self
shape shiftKey size
size size sourceIndex
span specified src
src src srcElement
srcFilter srcUrn start
start status status
styleFloat systemLanguage tabIndex
tableLayout tagName tagUrn
target text text
text text textAlign
textAutospace textDecoration textDecorationLineThrough
textDecorationNone textDecorationOverline textDecorationUnderline
textIndent textJustify textTransform
tFoot tHead title
title toElement top
top top topMargin
trueSpeed type type
type type type
type type type
type unicodeBidi uniqueID
units updateInterval URL
urn useMap userAgent
userLanguage vAlign vAlign
value value value
vcard_name verticalAlign visibility
vLink vlinkColor volume
vspace whiteSpace width
width width wordBreak
wordSpacing wrap x
XMLDocument y zIndex

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
empty Method execScript Method DHTML Met
Web Workshop | DHTML, HTML & CSS
execCommand Method
Executes a command over the given selection or text range.

Syntax

bSuccess = object.execCommand(sCommand [, bUserInterface] [, vValue])

Parameters

sCommand Required. String that specifies the command to execute, which can be any valid command identifier.
bUserInterface Optional. Boolean that specifies one of the following values:
false Default. Does not display a user interface.
true Displays a user interface, if the command supports one.
vValue Optional. Variant that specifies the string, number, or other value to assign. Possible values depend on sCommand.

Return Value

Boolean. Returns true if the command is successful, or false otherwise.

Remarks

Do not invoke the execCommand method until after the page loads.

Applies To

document, controlRange, TextRange

See Also

queryCommandEnabled, queryCommandIndeterm, queryCommandState,


queryCommandSupported, queryCommandValue

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
prompt Method queryCommandIndeterm Meth.
Web Workshop | DHTML, HTML & CSS
queryCommandEnabled Method
Returns whether the command can be successfully executed using execCommand, given
the current state of the document.

Syntax

bEnabled = object.queryCommandEnabled(sCmdID)

Parameters

sCmdID Required. String that specifies a command identifier.

Return Value

Boolean. Returns true if the command is enabled, or false otherwise.

Remarks

Using queryCommandEnabled("delete") on a TextRange object returns true, while


queryCommandEanbled("delete") on a document object returns false. However,
execCommand("delete") can still be used to delete the selected text.

Applies To

document, controlRange, TextRange

See Also

execCommand, queryCommandIndeterm, queryCommandState,


queryCommandSupported, queryCommandValue

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
queryCommandEnabled Metho... queryComman
Web Workshop | DHTML, HTML & CSS
queryCommandIndeterm Method
Returns whether the specified command is in the indeterminate state.

Syntax

bIndeterminate = object.queryCommandIndeterm(sCmdID)

Parameters

sCmdID Required. String that specifies a command identifier.

Return Value

Boolean. Returns true if indeterminate, or false otherwise.

Applies To

document, controlRange, TextRange

See Also

execCommand, queryCommandEnabled, queryCommandState,


queryCommandSupported, queryCommandValue

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
queryCommandIndeterm Meth... queryComma
Web Workshop | DHTML, HTML & CSS
queryCommandState Method
Returns the current state of the command.

Syntax

bDone = object.queryCommandState(sCmdID)

Parameters

sCmdID Required. String that specifies a command identifier.

Return Value

Boolean. Returns true if the given command has been executed on the object, false if
it has not, and null if it is not possible to determine the command state.

Applies To

document, controlRange, TextRange

See Also

execCommand, queryCommandEnabled, queryCommandIndeterm,


queryCommandSupported, queryCommandValue

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
queryCommandState Method queryCommandV
Web Workshop | DHTML, HTML & CSS
queryCommandSupported Method
Returns whether the current command is supported on the current range.

Syntax

bSupported = object.queryCommandSupported(sCmdID)

Parameters

sCmdID Required. String that specifies a command identifier.

Return Value

Boolean. Returns true if the command is supported, or false otherwise.

Applies To

document, controlRange, TextRange

See Also

execCommand, queryCommandEnabled, queryCommandIndeterm,


queryCommandState, queryCommandValue

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
queryCommandSupported Met... recalc Method
Web Workshop | DHTML, HTML & CSS
queryCommandValue Method
Returns the current value of the given command.

Syntax

vCmdValue = object.queryCommandValue(sCmdID)

Parameters

sCmdID Required. String that specifies a command identifier.

Return Value

String or Boolean. Returns a string representing the command value if the command is
supported, or true/false otherwise.

Remarks

If the command returns a value, such as a color, rather than a true/false state, this
command retrieves the current value of the document or range.

Applies To

document, controlRange, TextRange

See Also

execCommand, queryCommandEnabled, queryCommandIndeterm,


queryCommandState, queryCommandSupported

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BlockDirLTR Command | IDM... Command Iden
Web Workshop | DHTML, HTML & CSS
BackColor Command | IDM_BACKCOLOR Command ID
Sets or retrieves the background color of the current selection.

Scripting Information

Command BackColor
execCommand vValue Required. String that specifies one of the color names or red-green-blue (RGB) values in the Color Table.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_BACKCOLOR
User interface None
IOleCommandTarget::Exec parameters
pvaIn Required. VT_14 or VT_BSTR. Numeric red-green-blue (RGB) color value or
color name (such as white or black) taken from the Color Table.
pvaOut VT_14 or VT_BSTR. Numeric RGB color value or color name (such as white
or black) taken from the Color Table.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BlockDirRTL Command | IDM... BrowseMode Co
Web Workshop | DHTML, HTML & CSS
Bold Command | IDM_BOLD Command ID
Toggles the current selection between bold and nonbold.

Scripting Information

Command Bold
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_BOLD
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BrowseMode Command | IDM_... Copy Comma
Web Workshop | DHTML, HTML & CSS
IECMDID_CLEAR_AUTOCOMPLETE_FOR_FORMS Command ID
Clears saved forms data.

C++ Information

Command group CGID_InternetExplorer


Symbolic constant IECMDID_CLEAR_AUTOCOMPLETE_FOR_FORMS
User interface None
IOleCommandTarget::Exec parameters
pvaIn Required. One of the following values:

IECMDID_ARG_CLEAR_FORMS_ALL=0
IECMDID_ARG_CLEAR_FORMS_ALL_BUT_PASSWORDS=1
IECMDID_ARG_CLEAR_FORMS_PASSWORDS_ONLY=2

pvaOut Not applicable.


Header file Msiehost.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 5 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
IECMDID_CLEAR_AUTOCOMPLET... CreateBook
Web Workshop | DHTML, HTML & CSS
Copy Command | IDM_COPY Command ID
Copies the current selection to the clipboard.

Scripting Information

Command Copy
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_COPY
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Copy Command | IDM_COPY C... CreateLink Co
Web Workshop | DHTML, HTML & CSS
CreateBookmark Command | IDM_BOOKMARK Command ID
Retrieves the name of a bookmark anchor or creates a bookmark anchor for the current
selection or insertion point.

Scripting Information

Command CreateBookmark
execCommand vValue Required. String that specifies a valid anchor name. Providing an empty string will create the tag but will leave the anchor
name blank.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_BOOKMARK
User interface Yes
IOleCommandTarget::Exec parameters
pvaIn Required. VT_BSTR that specifies a valid anchor name. Providing an empty
string will create the tag but will leave the anchor name blank.
pvaOut VT_BSTR representing the anchor name of the bookmark.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CreateBookmark Command | ... Cut Command
Web Workshop | DHTML, HTML & CSS
CreateLink Command | IDM_HYPERLINK Command ID
Inserts a hyperlink on the current selection.

Scripting Information

Command CreateLink
execCommand vValue Required. String that specifies a URL. Providing an empty string will leave the URL blank.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_HYPERLINK
User interface Yes.
IOleCommandTarget::Exec parameters
pvaIn Required. VT_BSTR specifying a URL. Providing an empty string will leave
the URL blank.
pvaOut Not Applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CreateLink Command | IDM_... Delete Comman
Web Workshop | DHTML, HTML & CSS
Cut Command | IDM_CUT Command ID
Copies the current selection to the clipboard and then deletes it.

Scripting Information

Command Cut
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_CUT
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Cut Command | IDM_CUT Com... DirLTR Comm
Web Workshop | DHTML, HTML & CSS
Delete Command | IDM_DELETE Command ID
Deletes the current selection.

Scripting Information

Command Delete
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_DELETE
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
EditMode Command | IDM_ED... FontName Com
Web Workshop | DHTML, HTML & CSS
Find Command | IDM_FIND Command ID
Finds and selects text in the current document.

Scripting Information

Command Find
execCommand vValue Required. String that specifies the text to be found.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_FIND
User interface None
IOleCommandTarget::Exec parameters
pvaIn Required. BSTR specifying the text to be found.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 5 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Find Command | IDM_FIND C... FontSize Comm
Web Workshop | DHTML, HTML & CSS
FontName Command | IDM_FONTNAME Command ID
Sets or retrieves the font for the current selection.

Scripting Information

Command FontName
execCommand vValue Required. String that specifies a legal font name, as described by the FONT attribute.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_FONTNAME
User interface None
IOleCommandTarget::Exec parameters
pvaIn Required. VT_BSTR specifying a legal font name, as described by the FONT
attribute.
pvaOut VT_BSTR representing a legal font name, as described by the FONT
attribute.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
FontName Command | IDM_FO... ForeColor Co
Web Workshop | DHTML, HTML & CSS
FontSize Command | IDM_FONTSIZE Command ID
Sets or retrieves the font size for the current selection.

Scripting Information

Command FontSize
execCommand vValue Required. String that specifies the font size, as described by the size attribute. This must be a value between 0 and 7,
inclusive.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_FONTSIZE
User interface None
IOleCommandTarget::Exec parameters
pvaIn Required. VT_I4 specifying the font size, as described by the size attribute.
This must be a value between 0 and 7, inclusive.
pvaOut VT_I4 specifying the font size, as described by the size attribute. This will
be a value between 0 and 7, inclusive.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
FontSize Command | IDM_FO... FormatBlock Co
Web Workshop | DHTML, HTML & CSS
ForeColor Command | IDM_FORECOLOR Command ID
Sets or retrieves the foreground (text) color of the current selection.

Scripting Information

Command ForeColor
execCommand vValue Required. String that specifies one of the color names or red-green-blue (RGB) values in the Color Table.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_FORECOLOR
User interface None
IOleCommandTarget::Exec parameters
pvaIn Required. VT_I4 or VT_BSTR specifying a color. This can be any one of the
color names or values given in the Color Table.
pvaOut VT_I4 or VT_BSTR specifying a color. This will be one of the color names or
values given in the Color Table.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ForeColor Command | IDM_F... IDM_FONT Com
Web Workshop | DHTML, HTML & CSS
FormatBlock Command | IDM_BLOCKFMT Command ID
Sets or retrieves the current block format tag.

Scripting Information

Command FormatBlock
execCommand vValue Optional. String that specifies a valid block formatting tag.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_BLOCKFMT
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. BSTR specifying a valid block format tag.
pvaOut Optional. BSTR representing a valid block format tag.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Remarks

The available block formatting strings may change in subsequent releases of the
MSHTML component. Call IOleCommandTarget::Exec with the IDM_GETBLOCKFMTS
Command ID to obtain the current list of available block formatting commands that
can be passed with the IDM_BLOCKFMT Command ID.

Minimum Availability

Internet Explorer 4 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
IDM_GETBLOCKFMTS Command ... InlineDirLTR
Web Workshop | DHTML, HTML & CSS
Indent Command | IDM_INDENT Command ID
Increases the indent of the selected text by one indentation increment.

Scripting Information

Command Indent
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INDENT
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InlineDirRTL Command | ID... InsertFieldset Co
Web Workshop | DHTML, HTML & CSS
InsertButton Command | IDM_BUTTON Command ID
Overwrites a button control on the current selection.

Scripting Information

Command InsertButton
execCommand vValue Optional. String that specifies an identifier for the button control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_BUTTON
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the button control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertButton Command | ID... InsertHorizontal
Web Workshop | DHTML, HTML & CSS
InsertFieldset Command | IDM_INSFIELDSET Command ID
Overwrites a box on the current selection.

Scripting Information

Command InsertFieldset
execCommand vValue Optional. String that specifies an identifier for the box.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INSFIELDSET
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the box.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertFieldset Command | ... InsertIFrame Com
Web Workshop | DHTML, HTML & CSS
InsertHorizontalRule Command | IDM_HORIZONTALLINE
Command ID
Overwrites a horizontal line on the current selection.

Scripting Information

Command InsertHorizontalRule
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_HORIZONTALLINE
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the horizontal line.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertHorizontalRule Comm... InsertImage Com
Web Workshop | DHTML, HTML & CSS
InsertIFrame Command | IDM_IFRAME Command ID
Overwrites an inline frame on the current selection.

Scripting Information

Command InsertIFrame
execCommand vValue Optional. String that specifies an identifier for the inline frame.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_IFRAME
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the inline frame.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertIFrame Command | ID... InsertInputButto
Web Workshop | DHTML, HTML & CSS
InsertImage Command | IDM_IMAGE Command ID
Overwrites an image on the current selection.

Scripting Information

Command InsertImage
execCommand vValue Optional. String that specifies the path and name of the image file to be inserted.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_IMAGE
User interface Yes
IOleCommandTarget::Exec parameters
pvaIn Optional. VT_BSTR that specifies the path and file name of the image to be
inserted. If the default UI is toggled on, this parameter is ignored.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Remarks

If no path is provided for the image file, the path will default to the location of the
current document.

Minimum Availability

Internet Explorer 5 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertImage Command | IDM... InsertInputChe
Web Workshop | DHTML, HTML & CSS
InsertInputButton Command | IDM_INSINPUTBUTTON
Command ID
Overwrites a button control on the current selection.

Scripting Information

Command InsertInputButton
execCommand vValue Optional. String that specifies an identifier for the button control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INSINPUTBUTTON
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the button control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputButton Command... InsertInputFileU
Web Workshop | DHTML, HTML & CSS
InsertInputCheckbox Command | IDM_CHECKBOX Command ID
Overwrites a check box control on the current selection.

Scripting Information

Command InsertInputCheckbox
execCommand vValue Optional. String that specifies an identifier for the check box control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_CHECKBOX
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the check box control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputCheckbox Comma... InsertInputHidd
Web Workshop | DHTML, HTML & CSS
InsertInputFileUpload Command | IDM_INSINPUTUPLOAD
Command ID
Overwrites a file upload control on the current selection.

Scripting Information

Command InsertInputFileUpload
execCommand vValue Optional. String that specifies an identifier for the file upload control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INSINPUTUPLOAD
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the file upload control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputFileUpload Com... InsertInputImage
Web Workshop | DHTML, HTML & CSS
InsertInputHidden Command | IDM_INSINPUTHIDDEN
Command ID
Inserts a hidden control on the current selection.

Scripting Information

Command InsertInputHidden
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INSINPUTHIDDEN
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the hidden control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputHidden Command... InsertInputPass
Web Workshop | DHTML, HTML & CSS
InsertInputImage Command | IDM_INSINPUTIMAGE Command
ID
Overwrites an image control on the current selection.

Scripting Information

Command InsertInputImage
execCommand vValue Optional. String that specifies an identifier for the image control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INSINPUTIMAGE
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the image control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputImage Command ... InsertInputRad
Web Workshop | DHTML, HTML & CSS
InsertInputPassword Command | IDM_INSINPUTPASSWORD
Command ID
Overwrites a password control on the current selection.

Scripting Information

Command InsertInputPassword
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INSINPUTPASSWORD
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the password control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputPassword Comma... InsertInputRese
Web Workshop | DHTML, HTML & CSS
InsertInputRadio Command | IDM_RADIOBUTTON Command ID
Overwrites a radio control on the current selection.

Scripting Information

Command InsertInputRadio
execCommand vValue Optional. String that specifies an identifier for the radio control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_RADIOBUTTON
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the radio control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputRadio Command ... InsertInputSubm
Web Workshop | DHTML, HTML & CSS
InsertInputReset Command | IDM_INSINPUTRESET Command
ID
Overwrites a reset control on the current selection.

Scripting Information

Command InsertInputReset
execCommand vValue Optional. String that specifies an identifier for the reset control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INSINPUTRESET
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the reset control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputReset Command ... InsertInputText
Web Workshop | DHTML, HTML & CSS
InsertInputSubmit Command | IDM_INSINPUTSUBMIT
Command ID
Overwrites a submit control on the current selection.

Scripting Information

Command InsertInputSubmit
execCommand vValue Optional. String that specifies an identifier for the submit control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_INSINPUTSUBMIT
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the submit control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputSubmit Command... InsertMarquee
Web Workshop | DHTML, HTML & CSS
InsertInputText Command | IDM_TEXTBOX Command ID
Overwrites a text control on the current selection.

Scripting Information

Command InsertInputText
execCommand vValue Optional. String that specifies an identifier for the text control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_TEXTBOX
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the text control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertInputText Command |... InsertOrderedLis
Web Workshop | DHTML, HTML & CSS
InsertMarquee Command | IDM_MARQUEE Command ID
Overwrites an empty marquee on the current selection.

Scripting Information

Command InsertMarquee
execCommand vValue Optional. String that specifies an identifier for the marquee.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_MARQUEE
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the marquee.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertMarquee Command | I... InsertParagraph
Web Workshop | DHTML, HTML & CSS
InsertOrderedList Command | IDM_ORDERLIST Command ID
Toggles the current selection between an ordered list and a normal format block.

Scripting Information

Command InsertOrderedList
execCommand vValue Optional. String that specifies an identifier for the ordered list.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_ORDERLIST
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the ordered list.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Remarks

If the previous format block is already an ordered list, this command identifier will
append the current format block to that previous ordered list.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertOrderedList Command... InsertSelectDro
Web Workshop | DHTML, HTML & CSS
InsertParagraph Command | IDM_PARAGRAPH Command ID
Overwrites a line break on the current selection.

Scripting Information

Command InsertParagraph
execCommand vValue Optional. String that specifies an identifier for the paragraph.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_PARAGRAPH
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the paragraph.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertParagraph Command |... InsertSelectList
Web Workshop | DHTML, HTML & CSS
InsertSelectDropdown Command | IDM_DROPDOWNBOX
Command ID
Overwrites a drop-down selection control on the current selection.

Scripting Information

Command InsertSelectDropdown
execCommand vValue Optional. String that specifies an identifier for the drop-down selection control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_DROPDOWNBOX
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the drop-down selection
control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertSelectDropdown Comm... InsertTextArea
Web Workshop | DHTML, HTML & CSS
InsertSelectListbox Command | IDM_LISTBOX Command ID
Overwrites a list box selection control on the current selection.

Scripting Information

Command InsertSelectListbox
execCommand vValue Optional. String that specifies an identifier for the list box selection control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_LISTBOX
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the list box selection control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertSelectListbox Comma... InsertUnorderedL
Web Workshop | DHTML, HTML & CSS
InsertTextArea Command | IDM_TEXTAREA Command ID
Overwrites a multiline text input control on the current selection.

Scripting Information

Command InsertTextArea
execCommand vValue Optional. String that specifies an identifier for the text input control.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_TEXTAREA
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the text input control.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertTextArea Command | ... Italic Command
Web Workshop | DHTML, HTML & CSS
InsertUnorderedList Command | IDM_UNORDERLIST Command
ID
Toggles the current selection between an ordered list and a normal format block.

Scripting Information

Command InsertUnorderedList
execCommand vValue Optional. String that specifies an identifier for the unordered list.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_UNORDERLIST
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. String that specifies an identifier for the unordered list.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Remarks

If the previous format block is already an ordered list, this command identifier will
append the current format block to that previous ordered list.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
InsertUnorderedList Comma... JustifyCenter Co
Web Workshop | DHTML, HTML & CSS
Italic Command | IDM_ITALIC Command ID
Toggles the current selection between italic and nonitalic.

Scripting Information

Command Italic
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_ITALIC
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Italic Command | IDM_ITAL... JustifyFull Comm
Web Workshop | DHTML, HTML & CSS
JustifyCenter Command | IDM_JUSTIFYCENTER Command ID
Centers the format block in which the current selection is located.

Scripting Information

Command JustifyCenter
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_JUSTIFYCENTER
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
JustifyFull Command | IDM... JustifyNone Comm
Web Workshop | DHTML, HTML & CSS
JustifyLeft Command | IDM_JUSTIFYLEFT Command ID
Left-justifies the format block in which the current selection is located.

Scripting Information

Command JustifyLeft
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_JUSTIFYLEFT
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
JustifyNone Command | IDM... Open Command
Web Workshop | DHTML, HTML & CSS
JustifyRight Command | IDM_JUSTIFYRIGHT Command ID
Right-justifies the format block in which the current selection is located.

Scripting Information

Command JustifyRight
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_JUSTIFYRIGHT
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Open Command | IDM_OPEN C... OverWrite Co
Web Workshop | DHTML, HTML & CSS
Outdent Command | IDM_OUTDENT Command ID
Decreases by one increment the indentation of the format block in which the current
selection is located.

Scripting Information

Command Outdent
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_OUTDENT
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Outdent Command | IDM_OUT... Paste Comma
Web Workshop | DHTML, HTML & CSS
OverWrite Command | IDM_OVERWRITE Command ID
Toggles the text-entry mode between insert and overwrite.

Scripting Information

Command OverWrite
execCommand vValue Optional. Boolean that specifies the text-entry mode. If the value is set to true (the default), the text-entry mode is
overwrite. If set to false, it is insert.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_OVERWRITE
User interface None
IOleCommandTarget::Exec parameters
pvaIn Optional. VT_BOOL. If this value is set to true (the default), the text-entry
mode is overwrite. If this value is set to false, the text-entry mode is
insert.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
OverWrite Command | IDM_O... PlayImage Com
Web Workshop | DHTML, HTML & CSS
Paste Command | IDM_PASTE Command ID
Overwrites the contents of the clipboard on the current selection.

Scripting Information

Command Paste
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_PASTE
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Redo Command | IDM_REDO C... RemoveForm
Web Workshop | DHTML, HTML & CSS
Refresh Command | IDM_REFRESH Command ID
Refreshes the current document.

Scripting Information

Command Refresh
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_REFRESH
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Refresh Command | IDM_REF... RemoveParaFo
Web Workshop | DHTML, HTML & CSS
RemoveFormat Command | IDM_REMOVEFORMAT Command ID
Removes the formatting tags from the current selection.

Scripting Information

Command RemoveFormat
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_REMOVEFORMAT
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SaveAs Command | IDM_SAVE... SizeToControl
Web Workshop | DHTML, HTML & CSS
SelectAll Command | IDM_SELECTALL Command ID
Selects the entire document.

Scripting Information

Command SelectAll
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_SELECTALL
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
SuperScript Command | IDM... Underline Comm
Web Workshop | DHTML, HTML & CSS
UnBookmark Command | IDM_UNBOOKMARK Command ID
Removes any bookmark from the current selection.

Scripting Information

Command UnBookmark
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_UNBOOKMARK
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
UnBookmark Command | IDM_... Undo Comma
Web Workshop | DHTML, HTML & CSS
Underline Command | IDM_UNDERLINE Command ID
Toggles the current selection between underlined and not underlined.

Scripting Information

Command Underline
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_UNDERLINE
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Undo Command | UNDO Comma... Unselect Co
Web Workshop | DHTML, HTML & CSS
Unlink Command | IDM_UNLINK Command ID
Removes any hyperlink from the current selection.

Scripting Information

Command Unlink
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_UNLINK
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Unlink Command | IDM_UNLI... Command Iden
Web Workshop | DHTML, HTML & CSS
Unselect Command | IDM_CLEARSELECTION Command ID
Clears the current selection.

Scripting Information

Command Unselect
execCommand vValue Not applicable.
Applies to execCommand, queryCommandEnabled, queryCommandIndeterm, queryCommandState, queryCommandSupported,
queryCommandValue

C++ Information

Command group CGID_MSHTML


Symbolic constant IDM_CLEARSELECTION
User interface None
IOleCommandTarget::Exec parameters
pvaIn Not applicable.
pvaOut Not applicable.
Header file Mshtmcid.h
Applies to IOleCommandTarget::Exec, IOleCommandTarget::QueryStatus

Minimum Availability

Internet Explorer 4.0 and later

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
In implementing dhtml behavi... DHTML, HTML &
Web Workshop | DHTML, HTML & CSS
Default Behaviors Reference
dhtml behaviors provide a means for Web developers to extend the Microsoft® Internet
I
Explorer current object model. A number of behaviors have been implemented as part of
Internet Explorer 5 and are referred to as default behaviors.

The following links provide access to the object model exposed by these default behaviors.

Behaviors

anchor anim animation audio


clientCaps download homePage httpFolder
img media par saveFavorite
saveHistory saveSnapshot seq time
userData video

Properties

accelerate autoReverse availHeight availWidth


begin beginAfter beginEvent beginWith
bufferDepth clipBegin clipEnd clockSource
colorDepth connectionType cookieEnabled cpuClass
currTime decelerate dur end
endEvent endHold eventRestart expires
folder height image img
javaEnabled localTime onOffBehavior platform
player playerObject progressBehavior repeat
repeatDur sound src statics
syncBehavior syncTolerance systemLanguage target
timeAction timeline timelineBehavior timeStartRule
type userLanguage width XMLDocument

Methods

addComponentRequest addDABehavior beginElement clearComponentRequest


compareVersions doComponentRequest endElement getAttribute
getComponentVersion isComponentInstalled isHomePage load
navigate navigateFrame navigateHomePage pause
removeAttribute removeDABehavior resume save
setAttribute setHomePage startDownload

Events

onbegin onend onload onmediacomplete


onmedialoadfailed onmediaslip onpause onrepeat
onresume onresync onreverse onsave
onscriptcommand

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ISO Latin-1 Character Set DHTML References
Web Workshop | DHTML, HTML & CSS
HTML Character Sets
Character sets determine how the bytes that represent the text of your HTML document
are translated to readable characters. Microsoft® Internet Explorer interprets the bytes in
your document according to the applied character set translations. It interprets numeric or
hex character references ("&#12345;" or "&#x1234;") as ISO10646 code points,
consistent with the Unicode Standard, version 2.0, and independent of the chosen
character set. Named entities ("&") are displayed independently of the chosen character
set as well. The display of an arbitrary numeric character reference requires the existence
of a font that is able to display that particular character on the user's system. Accordingly,
the content in the first column of the following tables may not render as expected on all
systems.

ISO Latin-1 Character Set


Additional Named Entities for HTML
Character Entities for Special Symbols and BIDI Text
Character Set Recognition

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
all Collection DHTML References
Web Workshop | DHTML, HTML & CSS
DHTML Collections
The following is a list of the collections exposed by the Dynamic
HTML Object Model.

all anchors applets


areas attributes behaviorUrns
bookmarks boundElements cells
childNodes children controlRange
elements embeds filters
forms frames images
imports links mimeTypes
options plugins rows
rules scripts styleSheets
tBodies TextRectangle

The following is a list the methods that return collections.

getClientRects getElementsByName getElementsByTagName


tags urns

Did you find this topic useful? Suggestions for other topics? write
us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onabort Event DHTML References
Web Workshop | DHTML, HTML & CSS
DHTML Events
The following events are exposed by the Dynamic HTML Object Model.

onabort onafterprint onafterupdate


onbeforecopy onbeforecut onbeforeeditfocus
onbeforepaste onbeforeprint onbeforeunload
onbeforeupdate onblur onbounce
oncellchange onchange onclick
oncontextmenu oncopy oncut
ondataavailable ondatasetchanged ondatasetcomplete
ondblclick ondrag ondragend
ondragenter ondragleave ondragover
ondragstart ondrop onerror
onerrorupdate onfilterchange onfinish
onfocus onhelp onkeydown
onkeypress onkeyup onload
onlosecapture onmousedown onmousemove
onmouseout onmouseover onmouseup
onpaste onpropertychange onreadystatechange
onreset onresize onrowenter
onrowexit onrowsdelete onrowsinserted
onscroll onselect onselectstart
onstart onstop onsubmit
onunload

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
add DHTML References
Web Workshop | DHTML, HTML & CSS
DHTML Methods
The following is a list of the methods exposed by the
Dynamic HTML Object Model.

add addBehavior AddChannel


AddDesktopComponent AddFavorite addImport
addReadRequest addRule alert
appendChild applyElement assign
attachEvent AutoCompleteSaveForm AutoScan
back blur clear
clear clearAttributes clearData
clearInterval clearRequest clearTimeout
click cloneNode close
close collapse compareEndPoints
componentFromPoint confirm contains
createCaption createControlRange createElement
createRange createStyleSheet createTextNode
createTextRange createTFoot createTHead
deleteCaption deleteCell deleteRow
deleteTFoot deleteTHead detachEvent
doReadRequest doScroll duplicate
elementFromPoint empty execCommand
execScript expand findText
firstPage focus forward
getAdjacentText getAttribute getAttribute
getBookmark getBoundingClientRect getClientRects
getData getElementById getElementsByName
getElementsByTagName getExpression go
hasChildNodes ImportExportFavorites inRange
insertAdjacentElement insertAdjacentHTML insertAdjacentText
insertBefore insertCell insertRow
isEqual IsSubscribed item
javaEnabled lastPage mergeAttributes
move moveBy moveEnd
moveRow moveStart moveTo
moveToBookmark moveToElementText moveToPoint
namedRecordset navigate NavigateAndFind
nextPage open open
parentElement pasteHTML previousPage
print prompt queryCommandEnabled
p p p q y
queryCommandIndeterm queryCommandState queryCommandSupported
queryCommandValue recalc refresh
releaseCapture reload remove
removeAttribute removeBehavior removeChild
removeExpression removeNode removeRule
replace replaceAdjacentText replaceChild
replaceNode reset resizeBy
resizeTo scroll scrollBy
scrollIntoView scrollTo select
select setAttribute setCapture
setData setEndPoint setExpression
setInterval setTimeout ShowBrowserUI
showHelp showModalDialog showModelessDialog
splitText start stop
submit swapNode tags
taintEnabled urns write
writeln

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Color Table In dhtml tutorialsInt DHTML Reference
Web Workshop | DHTML, HTML & CSS
Tips and Tricks
As with any type of programming, writing bug-free, efficient scripts that meet your
expectations takes a bit of work. The following sections provide some tips and hints to
make that work take less time and go more smoothly.

Checking the Internet Explorer Version Number


Canceling a Button Click
Preventing a Document From Being Cached
Using Objects
Replacing Custom Controls with Dynamic HTML
Checking the Internet Explorer Version Number
Your scripts should always check the version of the client browser so your content will
degrade gracefully if the browser does not support the new features of Microsoft® Internet
Explorer version 4 or later. The easiest way to identify whether the browser is Internet
Explorer and determine its version number is to use the following JScript® (compatible
with ECMA 262 language specification) function:

function msieversion()
// Return Microsoft Internet Explorer (major) version number, or 0
for others.
// This function works by finding the "MSIE " string and extracting
the version number
// following the space, up to the decimal point for the minor
version, which is ignored.
{
var ua = window.navigator.userAgent
var msie = ua.indexOf ( "MSIE " )
if ( msie > 0 ) // is Microsoft Internet Explorer;
return version number
return parseInt ( ua.substring ( msie+5, ua.indexOf ( ".",
msie ) ) )
else
return 0 // is other browser
}

This function runs on most browsers and returns either the major version number for any
Microsoft Internet Explorer browser or zero for all other browsers. Use of this function
ensures that the script will be compatible with future versions of Internet Explorer.

Scripts should always check version numbers greater than or equal to a target version so
as to be compatible with future versions. Existing scripts that check for userAgent equal to
"MSIE 3" should be changed to check the version correctly so that these scripts will
recognize Internet Explorer 4.0, which supports all of the functionality of the previous
version.

The following example shows how to correctly check the client browser version.

if ( msieversion() >= 4 )
document.alert( "This is IE4 or later - safe to use all IE4
features" )
else if ( msieversion() >= 3 )
document.alert( "This is IE3 - safe to use ActiveX" )
else
document.alert( "This is not IE" )
Canceling a Button Click
The following HTML example shows a common scripting mistake related to event handling
and canceling the default action.

<HTML>
<HEAD><TITLE>Canceling the Default Action</TITLE>
<SCRIPT LANGUAGE=
"JScript"> function askConfirm()
{ return window.confirm ("Choose OK to follow hyperlink, Cancel
to
not.")
}

</SCRIPT> <BODYonload="b3.onclick=askConfirm">
<!-- Try links with different hookups - should be canceled by
"Cancel" to confirm dialog. -->

<BR><A NAME=b1 HREF="http://www.microsoft.com"


onclick="askConfirm()">1 Without return (won't work)</A>

<BR><A NAME=b2 HREF="http://www.microsoft.com" onclick="return


askConfirm()">2 With return (works)</A>

<BR><A NAME=b3 HREF="http://www.microsoft.com">3 Function pointer


(works)</A>

</BODY>
</HTML>

The first A element in this example does not work properly. Without the return in the
onclick JScript expression, the browser interprets the function expression, throws away the
resulting value, and leaves the default action unaffected.

The other A elements correctly bind the return value to the event, hence the default action
can be canceled when false is returned.
Preventing a Document From Being Cached
You can prevent a document from being cached by adding the following META tag to the
document.

<META HTTP-EQUIV="Expires" CONTENT="0">

Preventing the document from being cached ensures that a fresh copy of the document will
always be retrieved from the site, even during the user's current session, regardless of
how the user has set the browser's caching options. This is useful if the content of the
document changes frequently.
Using Objects
Objects are ActiveX® Controls or other similar components that provide custom
capabilities and services for HTML documents. You can add a control to your document by
using the OBJECT element, and you can gain access to the capabilities and services of the
control by using its properties and methods from script.

When using objects, be aware that Dynamic HTML extends every object by providing these
additional properties:

align classid code


codeBase codeType
data form
height name
object recordset
type width

If a control has properties with these same names, you will not be able to access the
properties unless you preface the name with the object property. For example, assume
that an ActiveX control is added to the document by using the following:

<OBJECT ID="MyControl" HEIGHT=100 WIDTH=200 CLASSID="clsid: ... ">


</PARAM NAME="width" VALUE="400">
</OBJECT>

In this example, there are two widths: an extended property set within the OBJECT
element, and a property belonging to the control that is set using the PARAM element. To
access these from script, you use the following code:

alert(MyControl.width); // this is Dynamic HTML's property;


displays "200"
alert(MyControl.object.width); // this is the object's property;
displays "400"
Replacing Custom Controls with Dynamic HTML
Dynamic HTML provides everything you need to generate animated effects without
resorting to custom controls. For example, consider the following script, which is a
replacement for the Path control.

var tickDuration;
tickDuration = 50;

var activeObjectCount;
var activeObjects;
var itemDeactivated;

var tickGeneration;

activeObjects = new Array();


activeObjectCount = 0;
timerRefcount = 0;
itemDeactivated = false;

tickGeneration = 0;

function initializePath(e) {
e.waypointX = new Array();
e.waypointY = new Array();
e.duration = new Array();

function addWaypoint(e, number, x, y, duration) {


e.waypointX[number] = x;
e.waypointY[number] = y;
e.duration[number] = duration;
}

function compact() {
var i, n, c;

n = new Array();
c = 0;
itemDeactivated = false;
for (i=0; i<activeObjectCount; i++) {
if (activeObjects[i].active == true) {
n[c] = activeObjects[i];
c++;
}
}
activeObjects = n;
activeObjectCount = c;
}

function tick(generation) {

if (generation < tickGeneration) {


// alert("Error "+generation);
return;
}

//alert("tick: "+generation);

if (itemDeactivated)
compact();

if (activeObjectCount == 0) {
return;
}
else {
for (i=0; i<activeObjectCount; i++) {
moveElement(activeObjects[i]);
}

window.setTimeout("tick("+generation+");", tickDuration);
}
}

function start(e) {
if (itemDeactivated)
compact();

activeObjects[activeObjectCount] = e;
activeObjectCount++;

if (activeObjectCount == 1) {
tickGeneration++;
tick(tickGeneration);
}
}

function runWaypoint(e, startPoint, endPoint) {

var startX, startY, endX, endY, duration;

if (e.waypointX == null)
return;
startX = e.waypointX[startPoint];
startY = e.waypointY[startPoint];
endX = e.waypointX[endPoint];
endY = e.waypointY[endPoint];

duration = e.duration[endPoint];
e.ticks = duration / tickDuration;

e.endPoint = endPoint;
e.active = true;
e.currTick = 0;

e.dx = (endX - startX) / e.ticks;


e.dy = (endY - startY) / e.ticks;

e.style.posLeft = startX;
e.style.posTop = startY;

start(e);
}

function moveElement(e) {
e.style.posLeft += e.dx;
e.style.posTop += e.dy;

e.currTick++;

if (e.currTick > e.ticks) {


e.active = false;
itemDeactivated = true;
if (e.onpathcomplete != null) {
window.pathElement = e;
e.onpathcomplete()
}
}
}

To use this script in your document, do the following:

1. Load the script by using the src attribute of the SCRIPT element.
2. Initialize the paths by using the initializePath function.
3. Set the way points by using the addWaypoint function.
4. Set the path-complete handlers using the runWaypoint function.

The following sample document show how this works.


<html>

<body>

<div id=Item1 style="position: absolute; left: 0; top:


0;">Item1</div>
<div id=Item2 style="position: absolute; left: 0; top:
0;">Item2</div>
<div id=Item3 style="position: absolute; left: 0; top:
0;">Item3</div>
<div id=Item4 style="position: absolute; left: 0; top:
0;">Item4</div>
<div id=Item5 style="position: absolute; left: 0; top:
0;">Item5</div>
<div id=Item6 style="position: absolute; left: 0; top:
0;">Item6</div>

<input type=button value="Start" onclick="runWaypoint(Item1, 0, 1);


runWaypoint(Item2, 0, 1);">
<div id=Debug>Generation</div>

<script src="htmlpath.js">
</script>

<script>

// need to call initializePath on all objects that will be moved


with this mechanism
initializePath(Item1);
initializePath(Item2);
initializePath(Item3);
initializePath(Item4);
initializePath(Item5);
initializePath(Item6);

// the 0th waypoint is the intial position for waypoint #1


// syntax is item, waypoint, endx, endy, duration in msecs
addWaypoint(Item1, 0, 0, 0, 0);
addWaypoint(Item1, 1, 200, 200, 2000);

addWaypoint(Item2, 0, 100, 100, 0);


addWaypoint(Item2, 1, 400, 100, 4000);

addWaypoint(Item3, 0, 400, 400, 0);


addWaypoint(Item3, 1, 200, 100, 1000);

addWaypoint(Item4, 0, 0, 0, 0);
addWaypoint(Item4, 1, 200, 200, 2000);

addWaypoint(Item5, 0, 100, 100, 0);


addWaypoint(Item5, 1, 400, 100, 4000);

addWaypoint(Item6, 0, 400, 400, 0);


addWaypoint(Item6, 1, 200, 100, 1000);

function endfunction() {
// syntax for runWaypoint is Item, start point, end point
runWaypoint(Item3, 0, 1);
runWaypoint(Item4, 0, 1);
runWaypoint(Item5, 0, 1);
runWaypoint(Item6, 0, 1);

function endfunction2() {
runWaypoint(Item1, 0, 1);
}

Item1.onpathcomplete = endfunction;
Item6.onpathcomplete = endfunction2;

</script>
</body>
</html>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the latest
version. Then reload this page to view the sample.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DHTML, HTML & CSS
Web Workshop | DHTML, HTML & CSS
Visual Filters and Transitions Reference
With the introduction of Microsoft® Internet Explorer 4.0,
Web page authors can now apply multimedia-style effects to
their content through the use of visual filters and
transitions. These effects are implemented in Web pages
using a cascading style sheet (CSS) attribute. Visual filters
and transitions can be applied to standard HTML controls,
such as text containers, images, and any other windowless
object. Transitions are time-varying filters that can create a
transition from one visual state to another. By combining
filters and transitions with basic scripting, authors have a
powerful tool for creating visually engaging and interactive
documents.

The following links provide access to the object model


exposed by these Visual Filters and Transitions.

Filters

alpha blendTrans blur chroma


dropShadow flipH flipV glow
gray invert light mask
redirect revealTrans shadow wave
xray

Properties

add color direction duration


enabled finishOpacity finishX finishY
freq lightStrength offX offY
opacity phase positive startX
startY status strength style
transition

Methods

addAmbient addCone addPoint apply


changeColor changeStrength clear elementImage
moveLight play stop

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
!DOCTYPE Element
Web Workshop | DHTML, HTML & CSS
HTML Elements
The following topics list the set of elements defined by
HTML. The links take you to the element definitions, which
contain the set of members for the element.

!DOCTYPE A ACRONYM ADDRESS APPLET AREA


B BASE BASEFONT BDO BGSOUND BIG
BLOCKQUOTE BODY BR BUTTON CAPTION CENTER
CITE CODE COL COLGROUP COMMENT custom
DD DEL DFN DIR DIV DL
DT EM EMBED FIELDSET FONT FORM
FRAME FRAMESET HEAD Hn HR HTML
HTML Comment I IFRAME IMG INPUT INPUT
type=button
INPUT INPUT INPUT INPUT INPUT INPUT
type=checkbox type=file type=hidden type=image type=password type=radio
INPUT INPUT INPUT INS ISINDEX KBD
type=reset type=submit type=text
LABEL LEGEND LI LINK LISTING MAP
MARQUEE MENU META NOBR NOFRAMES NOSCRIPT
OBJECT OL OPTION P PARAM PLAINTEXT
PRE Q RT RUBY S SAMP
SCRIPT SELECT SMALL SPAN STRIKE STRONG
STYLE SUB SUP TABLE TBODY TD
TEXTAREA TFOOT TH THEAD TITLE TR
TT U UL VAR WBR XML
XMP

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
font-variant Attribute | ... form Property DHT
Web Workshop | DHTML, HTML & CSS
font-weight Attribute | fontWeight Property
Sets or retrieves the weight of the font of the object.

Syntax

HTML { font-weight: sWeight }


Scripting object.style.fontWeight [ = sWeight ]

Possible Values

sWeight String that specifies one of the following values:


normal Font is normal.
bold Font is bold.
bolder Font is heavier than regular bold.
lighter Font is lighter than normal.
100 Font is at least as light as the 200 weight.
200 Font is at least as bold as the 100 weight and at least as light as the 300 weight.
300 Font is at least as bold as the 200 weight and at least as light as the 400 weight.
400 Font is normal.
500 Font is at least as bold as the 400 weight and at least as light as the 600 weight.
600 Font is at least as bold as the 500 weight and at least as light as the 700 weight.
700 Font is bold.
800 Font is at least as bold as the 700 weight and at least as light as the 900 weight.
900 Font is at least as bold as the 800 weight.

The property is read/write with a default value of normal; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Key words for font-weight values are mapped to specific font variations depending on
the fonts that are installed on the user's computer. In many cases, the user cannot see
the difference between different font-weight settings because the system chooses the
closest match.

Setting the font-weight to 400 is equivalent to normal, and 700 is equivalent to bold.
A font-weight of bolder or lighter is interpreted relative to the parent object's
weight. A value of bolder for text whose parent is normal would set the text to bold.

Internet Explorer 4.0 supports only normal and bold.

Internet Explorer 3.0 supports the font-weight attribute through the font attribute.

Example
The following examples use the font-weight attribute and the fontWeight property
to change the font weight.

This example uses LI as a selector in an embedded (global) style sheet to set the font
weight to bolder.

<STYLE>
LI { font-weight:bolder }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the font weight to bolder when an
onmouseover event occurs.

<P STYLE="font-size:14"
onmouseover="this.style.fontWeight='bolder'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

font

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | Component
Development
Component Development
For navigation tips, please see using this site .
I
This section contains information you'll need to create
components for your Web pages, using either ActiveX™ or
Dynamic HTML scriptlet technology.

ActiveX
We recommend reading the ActiveX controls introduction
I
and overview for starters. For a sampling of the
I
technology's versatility, read using activex with asp ,
I
creating activex components in c++ , and the abcs of mfc
I
activex controls .
I
HTML Components
Get acquainted with the DHTML Scriptlets Introduction and
Overview before diving into the Container Object Reference
and the Object Model Extensions.

Component Object Model (COM)


The section also provides related information about the
component object model (com) , the
I
//msdn.microsoft.com/workshop/components/dtctrl/doc/ove
rview.asp">design-time control sdk , the HTML
I
Components (HTC) Reference, downloading code on the
Web, and offline browsing .
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Component Development
Web Workshop | Component
Development
Welcome to Scriptlet Technology
Dynamic HTML (DHTML) scriptlets provide you with an easy
but powerful way to create controls from Web pages (.htm
files) that use Dynamic HTML. You can use scriptlets as
ordinary controls in applications such as Microsoft® Visual
Basic®, Microsoft® Internet Explorer version 4.0 and later,
and Microsoft® Visual InterDev™.

To See
Understand scriptlets and how they work Scriptlets Overview
Create scriptlets and add them to your applications Designing and Using
Scriptlets
Find descriptions of the properties, methods, and events that you can use Scriptlet Container
when including a scriptlet in your application Object Reference
Find descriptions of the properties, methods, and events that you can use Scriptlet Model
when creating a scriptlet Extensions

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Welcome to Scriptlet Tech...
Web Workshop | Component
Development
Designing a Scriptlet
A scriptlet is simply a DHTML page that uses certain
conventions to define its properties, methods, and events.

To define the page as a scriptlet:

Create a JScript® (compatible with ECMA 262


language specification) public_description object to
manage properties and methods. With this
convention, you explicitly define which properties and
methods the scriptlet will make available. Any
behavior that is not explicitly declared using the
public_description object is not available. For more
information, see Creating a public_description Object.

Or, use a default interface description. You do not


explicitly declare properties or methods. Instead, any
variables and functions that follow certain naming
conventions become available as properties and
methods. You can use this method if you want to
create scriptlet properties and methods in an active
scripting language other than JScript. For more
information, see Using Default Interface Descriptions.
Using a public_description object has several advantages.
You can use any names for variables and functions that you
want to expose as properties and methods because you
assign them public names in the public_description
object. In addition, using the public_description object
provides you with a convenient way to summarize and
document the properties and methods that the scriptlet
exposes.
In contrast, if you use the default interface descriptions,
you must use the public_ prefix on any name that you
want to expose. If a scriptlet already happens to have a
variable or function with the public_ prefix, it will always
be exposed, whether you want it to be or not.

When you create the properties, methods, and events for


the scriptlet, you can make full use of the DHTML Object
Model to display text, animate HTML elements, change
colors, or define any other behavior that you want the
control to have.

You can also use extensions to the DHTML Object Model


that are available as part of the window.external object,
which is unique to scriptlets. For a summary of the
extensions, see Scriptlet Model Extensions.

Note You can determine from within the .htm file whether it
is being used as a scriptlet or simply as a standalone Web
page. For details, see the version property.

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Welcome to Scriptlet Tech...
Web Workshop | Component
Development
Adding Scriptlets to Your Application
You can use scriptlets as you would any control.

To add a scriptlet to a Web page:

1. Define the scriptlet using an OBJECT tag, setting its


TYPE attribute to "text/x-scriptlet".
2. Specify the scriptlet's URL by setting the DATA
attribute in the OBJECT tag, as in the following
example:

<OBJECT ID="Scriptlet1"
TYPE="text/x-scriptlet"

DATA="http://myserver/sample.htm">

Or, specify a URL using the object's PARAM tag, as in


the following example:

<OBJECT ID="Scriptlet1" TYPE="text/x-


scriptlet" WIDTH=300 HEIGHT=200>
<PARAM NAME="url"
VALUE="http://myserver/sample.htm"
</OBJECT>

Note If you insert a scriptlet into a Web page using a


visual tool such as a toolbox or control insertion
dialog box, the resulting object definition might
include a CLASSID attribute instead of the TYPE
attribute.

To add a scriptlet to a host application:

1. Create a scriptlet container object in your application


and set its name property.
2. Set the scriptlet container object's url property to the
URL of the scriptlet you want to use.

Important If you are adding the scriptlet to a Web page,


do not set the url property to the URL of the current page.
Doing so causes a recursive call to the page and will cause
the browser to stop functioning.

You can add scroll bars if the scriptlet is too small to be


displayed within the container object. For details, see
scrollbar.

You can also resize the container object from within the
scriptlet by using a script to set the DHTML script object's
pixelHeight and pixelWidth properties. The following
example shows how you can resize the scriptlet container
when the scriptlet is first loaded.

<HTML ID="MyPage">
<HEAD>
<SCRIPT LANGUAGE="VBScript">
Sub window_onload()
MyPage.style.pixelHeight = 300
MyPage.style.pixelWidth = 400
End Sub
</SCRIPT>
</HEAD>

If you change the .htm file after creating the control, the
display in the control is not updated until the next time the
page is read. This occurs when the application is run or if
you change the url property of the control again.

Note After the scriptlet has been initialized, the F5 key,


used to refresh a page in Internet Explorer, is not active in
the scriptlet container object.

After creating an instance of the scriptlet, you can write


scripts for it as you would for any other control. The object
you are using to work with properties and methods is the
scriptlet container object; the exact properties and methods
you can use are defined by the scriptlet identified in the
container's url property.

Note If you are working in an environment that can display


an object's properties and methods, such as Visual Basic®,
you will not see the properties, because these are not
exposed to the development environment.

For example, the following code in a Visual Basic form sets


a property and calls a method in the page referenced by the
ScriptContainer1 control.
Sub cmdColor_Click()
ScriptContainer1.BackgroundColor="red"
ScriptContainer1.UpdateText (Text1.Text)
End Sub

Note In Visual Basic, you must pass a parameter to a


scriptlet method even if the method does not require one or
errors can occur. For example, the following statement
passes a placeholder parameter of zero to a scriptlet
method that does not require parameters:

ScriptContainer1.ToggleColor (0)

Before getting a scriptlet's properties or calling its methods,


be sure that the scriptlet has been fully loaded. For details,
see the container object's onreadystatechange event and
readyState property, and the scriptlet's frozen property.

Handling events that occur in the scriptlet is slightly


different than it is for events in other objects. For details,
see Defining Event Handlers.

See Also

Scriptlets Overview

Designing a Scriptlet
Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Welcome to Scriptlet Tech...
Web Workshop | Component
Development
Defining Event Handlers
When you use a scriptlet in your host application, the
application can be notified about events that occur in the
scriptlet. The scriptlet can expose two types of events:

Standard DHTML events such as the onclick event and


the onkeypress event. These events are triggered for
the scriptlet container object as a whole—using a
standard event, you cannot distinguish which control
within the scriptlet triggered the event. For more
information, see Handling Standard Events.
Custom events (events that you define or DHTML
events not provided as standard events). You can also
use custom events to pinpoint which control in the
scriptlet triggered the event. For more information,
see Defining Custom Events.

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
frozen Property Welcome to Scriptlet Tech...
Web Workshop | Component Development
event Property
Provides state information about a standard DHTML event passed from the scriptlet.

Applies To

Scriptlet object container

Syntax

value = ScriptContainer.event.member

Remarks

This property is read-only. The event property provides a way to get state information
about any of the standard events passed from the scriptlet: onclick, ondblclick,
onkeydown, onkeypress, onkeyup, onmousedown, onmousemove, onmouseup. This
property corresponds to the DHTML event object.

To get state information, you can query the values of the event property's members,
which include altKey, ctrlKey, keyCode, offsetX, offsetY, shiftKey,
srcElement, type, and others. The following example script illustrates how you can
use the event property to get more information about a standard event:

Sub ScriptContainer1_onkeyup()
MsgBox "The character typed was " &
ScriptContainer1.event.keyCode
MsgBox "The Alt key state was " &
ScriptContainer1.event.altKey
MsgBox "The Ctrl key state was " &
ScriptContainer1.event.ctrlKey
MsgBox "The Shift key state was " &
ScriptContainer1.event.shiftKey
MsgBox "The mouse was at " & offsetX & ", " & offsetY
MsgBox "The affected control was " &
ScriptContainer1.event.srcElement
MsgBox "The event was " & ScriptContainer1.event.type
End Sub

For more information about using the event property, refer to the event object in the
DHTML documentation.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
frozen Property scrollbar Property Welcome to
Web Workshop | Component Development
readyState Property
Returns information about the load state of the scriptlet hosted in the container object.

Applies To

Scriptlet container object

Syntax

ScriptContainer.readyState = integer

Remarks

This property is read-only. It is available only at runtime.

The readyState property returns an integer value between 1 and 4 indicating the load
state of the scriptlet, with the following values:

Value Definition
1 or 2 Undefined
3 Scriptlet text has been loaded, but controls on the scriptlet's .htm page might not yet be functional.
4 Scriptlet is completely loaded

In general, you should not attempt to access the scriptlet's functionality before the
readyState property is set to 4. You can check the value of this property in a handler for
the onreadystatechange event.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
scrollbar Property selectableContent Propert...
Web Workshop | Component Development
scrollbar Property
Specifies whether the scriptlet container object displays a scrollbar.

Applies To

scriptlet

Syntax

window.external.scrollbar = boolean

Remarks

This property provides a way to set the scriptlet container object's scrollbar property from
within the scriptlet.

By default, the value of this property is false. If you set this property to true:

A vertical scrollbar always appears in the scriptlet container object. If the scriptlet's
height is less than the height of the scriptlet container object's window, the vertical
scrollbar is disabled.

A horizontal scrollbar appears if the scriptlet's width is greater than the width of the
scriptlet container object's window
To set the size of the scriptlet container object window from within the scriptlet, see
Adding Scriptlets to Your Application.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
selectableContent Propert... version Property
Web Workshop | Component Development
url Property
Specifies the Universal Resource Locator (URL) of the scriptlet's .htm file to be displayed in
the scriptlet container object.

Applies To

Scriptlet container object

Syntax

ScriptContainer.url = URLString

Remarks

You can specify the URL of any .htm file, either local or on a Web server. This property can
be set at design time only.

Important If you are adding the scriptlet to a Web page, do not set this property to the
URL of the current page. Doing so causes a recursive call to the page and will cause the
browser stop functioning.

If you are using the scriptlet in a host application that has a Web context (such as Internet
Explorer), you can specify an absolute path (for example, http://myserver/start.htm) or a
relative path that does not include the protocol, or domain, or path (for example,
page2.htm). If you specify a relative URL, the path is relative to the page in which the
scriptlet appears.

If you specify a URL that is not valid, no error message is displayed, but the scriptlet
container object remains blank.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ondblClick Event Welcome to Scriptlet Tech...
Web Workshop | Component Development
onclick Event
Sent when the scriptlet forwards an onclick event.

Visual Basic Syntax


ScriptContainer_onclick()

JavaScript Syntax

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= onclick>

Remarks

The scriptlet container object receives this event if both of these conditions are true:

The scriptlet contains a handler for the onclick event.


The scriptlet's handler calls the bubbleEvent method to pass the event to the host
application.
You can get information about the state of the event by querying the scriptlet object
container's event property.

Applies To
Scriptlet container object

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onClick Event onkeyDown Event Welcome to
Web Workshop | Component Development
ondblclick Event
Sent when the scriptlet forwards an ondblclick event.

Visual Basic Syntax

ScriptContainer_ondblClick()

JavaScript Syntax

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= ondblClick>

Remarks

The scriptlet container object receives this event if both of these conditions are true:

The scriptlet contains a handler for the ondblclick event.


The scriptlet's handler calls the bubbleEvent method to pass the event to the host
application.
You can get information about the state of the event by querying the scriptlet object
container's event property.

Applies To

Scriptlet container object

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ondblClick Event onkeyPress Event Welcome
Web Workshop | Component Development
onkeydown Event
Sent when the scriptlet forwards an onkeydown event.

Visual Basic Syntax

ScriptContainer_onkeydown()

JavaScript Syntax

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= onkeydown()>

Remarks

The scriptlet container object receives this event if both of these conditions are true:

The scriptlet contains a handler for the onkeydown event.


The scriptlet's handler calls the bubbleEvent method to pass the event to the host
application.
You can get information about the state of the event by querying the scriptlet object
container's event property.

Applies To

Scriptlet container object

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onkeyDown Event onkeyUp Event Welcome to
Web Workshop | Component Development
onkeypress Event
Sent when the scriptlet forwards an onkeypress event.

Applies To

Scriptlet container object

Visual Basic Syntax

ScriptContainer_onkeypress()

JavaScript Syntax

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= onkeypress()>

Remarks

The scriptlet container object receives this event if both of these conditions are true:

The scriptlet contains a handler for the onkeypress event.

The scriptlet's handler calls the bubbleEvent method to pass the event to the host
application.
You can get information about the state of the event by querying the scriptlet object
container's event property.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onkeyPress Event onmousedown, onmouseup E
Web Workshop | Component Development
onkeyup Event
Sent when the scriptlet forwards an onkeyup event.

Applies To

Scriptlet container object

Visual Basic Syntax

ScriptContainer_onkeyup()

JavaScript Syntax

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= onkeyup()>

Remarks

The scriptlet container object receives this event if both of these conditions are true:

The scriptlet contains a handler for the onkeyup event.

The scriptlet's handler calls the bubbleEvent method to pass the event to the host
application.
You can get information about the state of the event by querying the scriptlet object
container's event property.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onkeyUp Event onmousemove Event Welcom
Web Workshop | Component Development
onmousedown, onmouseup Events
Sent when the scriptlet forwards an onmousedown or onmouseup event.

Applies To

Scriptlet container object

Visual Basic Syntax

ScriptContainer_onmousedown()

ScriptContainer_onmouseup()

JavaScript Syntax

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= onmousedown()>

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= onmouseup()>

Remarks

The scriptlet container object receives this event if both of these conditions are true:

The scriptlet contains a handler for the onmousedown or onmouseup event.

The scriptlet's handler calls the bubbleEvent method to pass the event to the host
application.
You can get information about the state of the event by querying the scriptlet object
container's event property.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onmousedown, onmouseup Ev... onreadystatec
Web Workshop | Component Development
onmousemove Event
Sent when the scriptlet forwards an onmousemove event.

Applies To

Scriptlet container object

Visual Basic Syntax

ScriptContainer_onmousemove()

JavaScript Syntax

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= onmousemove()>

Remarks

The scriptlet container object receives this event if both of these conditions are true:

The scriptlet contains a handler for the onmousemove event.

The scriptlet's handler calls the bubbleEvent method to pass the event to the host
application.
You can get information about the state of the event by querying the scriptlet object
container's event property.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onmousemove Event onscriptletevent Event W
Web Workshop | Component Development
onreadystatechange Event
Sent to indicate whether the scriptlet has completed loading.

Applies To

Scriptlet container object

Visual Basic Syntax

ScriptContainer_onreadystatechange ()

JavaScript Syntax

< SCRIPT LANGUAGE="JavaScript"


FOR=ScriptContainer
EVENT= onreadystatechange>

Remarks

This event is fired multiple times while the scriptlet is loading. The final time, it indicates
that the scriptlet's .htm page is fully loaded and its scripts can be called. To test the
current state, you can get the value of the scriptlet container object's readystate property.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onreadystatechange Event Welcome to Scriptle
Web Workshop | Component Development
onscriptletevent Event
Notifies the scriptlet container object that a custom event has occurred in the scriptlet.

Applies To

Scriptlet container object

Syntax

ScriptContainer_onscriptletevent( eventName, eventObject )

Parameters

eventName

A string that typically identifies the event that is being passed.

eventObject

A variant type that typically is a reference to an object on the scriptlet.

Note The exact content of both parameters depends on what information was passed in
the scriptlet's corresponding raiseEvent method.

Remarks

This event is the complement of the scriptlet's raiseEvent method. For more information,
see Defining Custom Events. For information about notifying the host application about
standard events, see Handling Standard Events.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
event Property readyState Property Welcome
Web Workshop | Component Development
frozen Property
Indicates whether the scriptlet container object is ready to handle events.

Applies To

Scriptlet

Syntax

boolean = window.external.frozen

Remarks

This property is read-only. When it is True, events will not be received by the scriptlet
container object because the container is not yet ready. When it is False, the container will
receive event notification.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
scrollbar Property url Property Welcome to Sc
Web Workshop | Component Development
selectableContent Property
Specifies whether the user can select the contents of the scriptlet.

Applies To

Scriptlet

Syntax

window.external.selectableContent = boolean

Remarks

By default, the value of this property is false. If this property is true, users can select text
or objects in the scriptlet while it is shown in the scriptlet container object, and then copy
or drag them. If this property is false, users can click objects in the scriptlet, but cannot
select them.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
url Property Welcome to Scriptlet Tech...
Web Workshop | Component Development
version Property
Returns the version and platform of the scriptlet container object DLL.

Applies To

Scriptlet

Syntax

version = window.external.version

Remarks

This property is read-only. Version is returned in the format N.nnnn platform


where N is an integer representing the major version number, nnnn is any number
of characters (except a space) representing the minor version number, and
platform is the platform (win32, mac, alpha, and so on). The following is an
example version number:

1.0a win32

You can use the version property to determine whether the page is being used
as a scriptlet or as a standalone Web page. Use a statement such as the following:

controlMode = ( typeof( window.external.version) == "string"


)

If the value of controlMode is true after this statement has executed, the page
is being used as a scriptlet. Otherwise the page is being used as a standalone
page.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
raiseEvent Method Welcome to Scriptlet Tech...
Web Workshop | Component Development
bubbleEvent Method
Sends event notification for a standard event to the host application.

Applies To

Scriptlet

Syntax

window.external.bubbleEvent()

Remarks

Use this method to pass a standard DHTML event (such as onbuttonclick, onmousemove,
or onkeypress) from the scriptlet to the host application. For more details, see Handling
Standard Events.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
bubbleEvent Method setContextMenu Method
Web Workshop | Component Development
raiseEvent Method
Passes a custom event notification from the scriptlet to the host application.

Applies To

Scriptlet

Syntax

window.external.raiseEvent( eventName, eventObject )

Parameters

eventName

A string that typically identifies the event that is being passed.

eventObject

A variant type that typically includes a reference to the object on the scriptlet that
triggered the event.

Remarks

This method is the complement of the scriptlet container object's onscriptletevent event.
Use this method to notify the host application about a non-standard event. For more
information, see Defining Custom Events. For information about notifying the host
application about standard events, see Handling Standard Events.

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
raiseEvent Method Welcome to Scriptlet Tech...
Web Workshop | Component Development
setContextMenu Method
Constructs a context menu that is displayed when a user right-clicks a scriptlet in the
scriptlet container object.

Applies To

Scriptlet

Syntax

window.external.setContextMenu( menuDefinition )

Parameters

menuDefinition
Defines the command text and commands contained in the context menu. A one-
dimensional array in which the menu items are defined using sequences of two
elements, n and n+1.

Element n The command text. Shortcut keys are defined by preceding a letter with "&".
Element n+1 The method to be called when the command is chosen. You cannot pass parameters to the method.

Note Context menus can only be defined in scripts written in VBScript or JavaScript,
because only those languages can create arrays usable by the setContextMenu
method.

For example, the following script defines a context menu with three commands:

<SCRIPT LANGUAGE="VBScript" FOR="Menu" EVENT="onClick">


' Define array
dim menuItems(6) ' 3 commands

' First menu item


menuItems(0) = "Display the &time" ' Command text
menuItems(1) = "SetTime"

' Second menu item


menuItems(2) = "Display the &date" ' Command text
menuItems(3) = "SetDate"

' Third menu item


menuItems(4) = "Display the document t&itle" ' Command text
menuItems(5) = "SetTitle"

' Assigns the menu to the scriplet


' window.external.setContextMenu(menuItems)
</SCRIPT>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BEHAVIOR Attribute | beha... BGCOLOR Attribu
Web Workshop | DHTML, HTML & CSS
behavior Attribute | behavior Property
Sets or retrieves the location of the dynamic html (dhtml) behavior .
I
Syntax

HTML { behavior : sBehavior }


Scripting object.style.behavior [ = sBehavior ]

Possible Values

sBehavior String that specifies one of the following values:


url(sLocation) Script implementation of a DHTML behavior, where sLocation is an absolute or
relative URL.
url(#objID) Binary implementation of a DHTML behavior, where objID is the ID attribute
specified in an OBJECT tag.
url(#default#behaviorName) One of Internet Explorer's default behaviors, identified by its behaviorName.

The property is read/write with no default value; the proposed cascading style sheets
(CSS) extension attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

You can apply multiple behaviors to an element by specifying a space-delimited list of


URLs for the behavior attribute, as shown in the following syntax:

<ELEMENT STYLE="behavior:url(a1.htc) url(a2.htc) ..." >

In the following Example section, one example demonstrates how two behaviors can
be applied to an element to achieve a combination of effects. Conflicts resulting from
applying multiple behaviors to an element are resolved based on the order in which the
behavior is applied to the element. Each succeeding behavior takes precedence over
the previous behavior in the order. For example, if multiple behaviors set the element's
color, the prevailing color is the one set by the behavior last applied to the element.
The same rule applies in resolving name conflicts, such as with property, method, or
event names exposed by multiple behaviors.

Once the behavior property has been defined for the element, the addBehavior
method can be used to dynamically attach additional behaviors to the element.

Note A behavior attached to an element by using the addBehavior method or by


applying the proposed CSS behavior attribute inline is not automatically detached
from the element when the element is removed from the document hierarchy.
However, a behavior attached using a style rule defined in the document is detached
automatically as the element is removed from the document tree.
Example

The following examples demonstrate various ways of applying the behavior property
on a page.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BGSOUND, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE, CODE,
COL, COLGROUP, COMMENT, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn, HR,
HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, ISINDEX, KBD, LABEL, LEGEND, LI, LINK,
LISTING, MAP, MARQUEE, MENU, NEXTID, NOBR, NOFRAMES, NOSCRIPT, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP,
SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, STYLE, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR,
WBR, XML, XMP

See Also

using dhtml behaviorsI

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
DIRECTION Attribute | dir... DISABLED Attribut
Web Workshop | DHTML, HTML & CSS
direction Attribute | direction Property
Sets or retrieves the reading order of the specified object.

Syntax

HTML { direction:sDirection }
Scripting object.style.direction [ =sDirection ]

Possible Values

sDirection String that specifies one of the following values:


ltr Text flow is left-to-right.
rtl Text flow is right-to-left.
inherit Text flow value is inherited.

The property is read/write with a default value of ltr.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Applies To

A, ACRONYM, ADDRESS, AREA, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle,
custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, Hn, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT
type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, KBD,
LABEL, LEGEND, LI, LISTING, MAP, MARQUEE, MENU, NOBR, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, runtimeStyle, S, SAMP,
SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

dir

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
float Attribute | styleFl... font-family Attribute |
Web Workshop | DHTML, HTML & CSS
font Attribute | font Property
Sets or retrieves up to six separate font properties of the object.

Syntax

HTML { font: sFont }


Scripting object.style.font [ = sFont ]

Possible Values

sFont String that specifies up to six of the space-delimited values listed first in the following table, plus one or more of the values listed after them:
font-style Any of the range of font-style values available to the fontStyle property.
font-variant Any of the range of font-variant values available to the fontVariant property.
font-weight Any of the range of font-weight values available to the fontWeight property.
font-size Any of the range of font-size values available to the fontSize property.
line-height Any of the range of line-height values available to the lineHeight property.
font-family Any of the range of font-family values available to the fontFamily property.
caption Text font used in objects that have captions (buttons, labels, and so on).
icon Text font used in icon labels.
menu Text font used in menus.
messagebox Text font used in dialog boxes.
smallcaption Text font used in small controls.
statusbar Text font used in window status bars.

The property is read/write with the default value set by the browser; the cascading
style sheets (CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This is a composite property that specifies up to six font values, in the following order:
font-style, font-variant, font-weight, font-size, line-height, font-family. Setting
the font property also sets the component properties. In this case, the string must be
a combination of valid values for the component properties, with no more than one
value per property. If the string does not contain a value for a component property,
that property is set to its default.

Example

The following examples use the font attribute and the font property to change font
characteristics.

This example uses an inline style sheet to set the font attributes.

<SPAN STYLE="font:italic normal bolder 12pt Arial">


:
</SPAN>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the font properties.

<DIV onmouseover="this.style.font = 'italic small-caps bold 12pt


serif'">
:
</DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD, DFN, DIR, DIV, DL, DT, EM,
FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password,
INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH,
THEAD, TR, TT, U, UL, VAR, XMP

See Also

CSS Length Units

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
@charset Rule @import Rule DHTML Propertie
Web Workshop | DHTML, HTML & CSS
@font-face Rule
Sets a font to embed in the HTML document.

Syntax

HTML @font-face { sFace }


Scripting N/A

Possible Values

sFace String that specifies one of the following values:


font-family:fontFamilyName Any of the range of values available to the fontFamily property.
src:url(sURL) Location of the font file, where sURL is an absolute or relative URL.

The rule has no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This feature allows you to use specific fonts that might not be available on your local
system. The URL should point to an embedded OpenType file (.eot or .ote format). The
file contains compressed font data that is converted to a TrueType font. For more
information about the font embedding feature and pointers to a tool for creating .eot
files, see font embedding .
I
Example

This example embeds a font in an HTML document by referencing its source from
another site.

<HTML>
<HEAD>
<STYLE>
@font-face {
font-family:comic;
src:url(http://valid_url/some_font_file.eot);
}
</STYLE>
</HEAD>
<BODY>
<P STYLE="font-family:comic;font-size:18pt">
This paragraph uses the font-face rule defined
in the above style element. The rule embeds
an OpenType file for the Comic Sans font.
</P>
</BODY>
</HTML>

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
font Attribute | font Pro... font-size Attribute | f
Web Workshop | DHTML, HTML & CSS
font-family Attribute | fontFamily Property
Sets or retrieves the name of the font used for text in the object.

Syntax

HTML { font-family: sFamily }


Scripting object.style.fontFamily [ = sFamily ]

Possible Values

sFamily String that specifies one of the following values:


family-name Any of the available font families supported by the browser (for example, Times, Helvetica,
Zapf-Chancery, Western, or Courier).
generic-name Any of the following font families: serif, sans-serif, cursive, fantasy, or monospace.

The property is read/write with the default value set by the browser; the cascading
style sheets (CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The value is a prioritized list of font family names and/or generic family names. List
items are separated by commas to minimize confusion between multiple-word font
family names. If the font family name contains white space, it should be quoted with
single or double quotation marks; generic font family names are values and,
accordingly, no quotes should be used.

Because you don't know which fonts users have installed, you should provide a list of
alternatives with a generic font family at the end of the list. This list can include
embedded fonts. For more information about embedding fonts, see the @font-face
rule.

If fantasy is specified for generic-name, the text renders in the default font.

Example

The following examples use the font-family attribute and the fontFamily property to
change font characteristics.

This example uses a call to an embedded style sheet to set the font family.

<STYLE>
P { font-family:"Arial"}
.other { font-family:"Courier"}
</STYLE>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the font family when an onmousedown
event occurs.

<DIV onmousedown="this.style.fontFamily='Courier'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BASEFONT, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN,
DIR, DIV, DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

font

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
font-family Attribute | f... fontSmoothingEnable
Web Workshop | DHTML, HTML & CSS
font-size Attribute | fontSize Property
Sets or retrieves the size of the font used for text in the object.

Syntax

HTML { font-size: sSize }


Scripting object.style.fontSize [ = sSize ]

Possible Values

sSize String that specifies one of the following values:


absolute-size Set of keywords that indicate predefined font sizes. Possible keywords include
[ xx-small | x-small | small | medium | large | x-large | xx-large ]. Named font sizes scale
according to the user's font setting preferences.
relative-size Set of keywords that are interpreted as relative to the font size of the parent object. Possible values
include [ larger | smaller ].
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the parent object's font size. In Internet
Explorer 3.0, the value is calculated as a percentage of the default font size.

The property is read/write with a default value of medium; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Negative values are not allowed. Font sizes using the proportional "em" measure are
based on the font size of the parent object.

Possible length values specified in a relative measurement, using the height of the
element's font (em) or the height of the letter "x" (ex), are supported in Internet
Explorer 4.0 and later.

Example

The following examples use the font-size attribute and the fontSize property to
change font characteristics.

This example sets the font size on several paragraphs using different size values.

<STYLE>
BODY{font-size: 10pt }
.P1 {font-size: 14pt }
.P2 {font-size: 75% }
.P3 {font-size: xx-large }
.P4 {font-size: larger }
</STYLE>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the font size to 14pt when an onmouseover
event occurs.

<DIV STYLE="font-size:12pt"
onmouseover="this.style.fontSize='14pt'">
:
</DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN,
DIR, DIV, DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

font, CSS Length Units

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
fontSmoothingEnabled Prop... font-variant Attr
Web Workshop | DHTML, HTML & CSS
font-style Attribute | fontStyle Property
Sets or retrieves the font style of the object as italic, normal, or oblique.

Syntax

HTML { font-style: sStyle }


Scripting object.style.fontStyle [ = sStyle ]

Possible Values

sStyle String that specifies one of the following values:


normal Font is normal.
italic Font is italic.
oblique Font is italic.

The property is read/write with a default value of normal; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The oblique value is available as of Internet Explorer 4.0. Internet Explorer 4.0
renders italic and oblique identically.

Example

The following examples use the font-style attribute and the fontStyle property to
change font characteristics.

This example uses H3 as a selector to set the font style to italic in H3 headings.

<STYLE>
H3 { font-style:italic }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the font style to italic when an
onmousedown event occurs.

<DIV onmousedown="this.style.fontStyle='italic'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.
Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

font

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
font-style Attribute | fo... font-weight Attribute
Web Workshop | DHTML, HTML & CSS
font-variant Attribute | fontVariant Property
Sets or retrieves whether the text of the object is in small capital letters.

Syntax

HTML { font-variant: sVariant }


Scripting object.style.fontVariant [ = sVariant ]

Possible Values

sVariant String that specifies one of the following values:


normal Font is normal.
small-caps Font is in small capital letters.

The property is read/write with a default value of normal; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Internet Explorer 4.0 renders small-caps as uppercase letters in a smaller size.

Example

The following examples use the font-variant attribute and the fontVariant property
to change the font to small capitals.

This example uses P as a selector in an embedded (global) style sheet to set the font
style to small-caps in all paragraphs.

<P STYLE="font-variant:small-caps">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the font style to small-caps when an
onmousedown event occurs.

<DIV onmousedown="this.style.fontVariant='small-caps'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To
A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

font

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ID Attribute | id Propert... indeterminate Prope
Web Workshop | DHTML, HTML & CSS
ime-mode Attribute | imeMode Property
Sets or retrieves the state of an Input Method Editor (IME).

Syntax

HTML { ime-mode: sMode }


Scripting object.style.imeMode [ = sMode ]

Possible Values

sMode String that specifies one of the following values:


auto IME is not affected. This is the same as not specifying the ime-mode attribute.
active All characters are entered through the IME. Users can still deactivate the IME.
inactive All characters are entered without IME. Users can still activate the IME.
disabled IME is completely disabled. Users cannot activate the IME if the control has focus.

The property is read/write with a default value of auto; the proposed cascading style
sheets (CSS) extension attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

An Input Method Editor (IME) allows users to enter and edit Chinese, Japanese, and
Korean characters. The IME is an essential component for writing Chinese, Japanese,
and Korean scripts. These writing systems have more characters than can be encoded
for a regular keyboard. The IMEs for these languages use sequences of base
characters that describe an individual character or group of characters to enter a larger
set of characters. Base characters can be component letters from Hangul syllables,
phonetic components for Japanese Kanji characters, or various combinations for
Chinese characters.

To compose text with an IME, the user generally uses dictionary lookup and contextual
analysis, especially in languages where homonyms are frequent, as in Japanese. A
user typically starts by entering a few component characters, optionally selecting from
various choices, and a confirmation command.

Input Method Editors have two principle states:

Inactive mode. The keyboard acts like a regular keyboard and input is limited to
a small set of characters.
Active mode. The IME accepts component characters or processing commands.
HTML authors can provide users with some control by specifying an IME mode for a
specific text entry. For example, if Japanese users enter information in a registration
form, they might be required to enter their names in Kanji and Roman characters. By
default, the users would have to make sure that the IME is inactive when entering their
names in the Latin alphabet. The user would activate the IME to enter Kanji letters,
then deactivate the IME to complete the form in the Latin alphabet. By controlling the
IME mode, the HTML author prevents the user from having to activate and deactivate
the IME.

Example

This example uses the ime-mode attribute.

<INPUT TYPE = text STYLE = "ime-mode:active" >

Applies To

INPUT_text, TEXTAREA

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
lastModified Property layout-grid-char Attribut.
Web Workshop | DHTML, HTML & CSS
layout-grid Attribute | layoutGrid Property
Sets or retrieves the composite document grid properties that specify the layout of text
characters.

Syntax

HTML { layout-grid: sLayout ... }


Scripting oObject.style.layoutGrid [ = sLayout ]

Possible Values

sLayout String that specifies one or more of the following values:


mode Any of the range of mode values available to the layoutGridMode property.
type Any of the range of type values available to the layoutGridType property.
line Any of the range of line values available to the layoutGridLine property.
char Any of the range of character values available to the layoutGridChar property.
space Any of the range of space values available to the layoutGridCharSpacing property.

The property is read/write with no default value; the proposed cascading style sheets
(CSS) extension attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Web documents in East Asian languages, such as Chinese or Japanese, usually create a
page layout for characters using a one- or two-dimensional grid. You can use the
layout-grid attribute to incorporate this layout into Web documents.

Example

This example uses the layout-grid attribute to specify character layout for a block of
text.

<STYLE>
DIV.layout { layout-grid: char line 12px 12px .5in }
</STYLE>

<DIV CLASS = "layout">


This is a block element containing a sentence of sample text.
</DIV>

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE, CODE, COL,
COLGROUP, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn, HR, I, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, INS, KBD, LABEL, LEGEND, LI, LISTING, MAP, MARQUEE, MENU, META, NEXTID, NOBR, OBJECT, OL,
OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, runtimeStyle, S, SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE,
TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
layout-grid Attribute | l... layout-grid-char-spac
Web Workshop | DHTML, HTML & CSS
layout-grid-char Attribute | layoutGridChar Property
Sets or retrieves the size of the character grid used for rendering the text content of an
element.

Syntax

HTML { layout-grid-char: sCharSize }


Scripting oObject.style.layoutGridChar [ = sCharSize ]

Possible Values

sCharSize String that specifies one of the following values:


none No character grid is set.
auto Largest character in the font of the element is used to set the character grid.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage derived from the dimensions of the parent
object.

The property is read/write with a default value of none; the proposed cascading style
sheets (CSS) extension attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The visual effects of the layout-grid-char attribute are similar to the lineHeight
property.

Web documents in East Asian languages, such as Chinese or Japanese, usually create a
page layout for characters using a one- or two-dimensional grid. You can use the
layout-grid attribute to incorporate this layout into Web documents.

The layout-grid-char attribute applies only to block-level elements.

Note For this property to have an effect, the layout-grid-mode attribute must be set to
line or both.

Example

This example uses the layout-grid-char attribute to specify character layout for a
block of text.

<STYLE>
DIV.layout { layout-grid-char: auto }
</STYLE>
<DIV CLASS = "layout">
This is a block element containing a sentence of sample text.
</DIV>

Applies To

BLOCKQUOTE, BODY, CENTER, currentStyle, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, LI, LISTING, MARQUEE, MENU, OL, P, PLAINTEXT,
PRE, runtimeStyle, style, TABLE, TD, TH, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
layout-grid-char Attribut... layout-grid-line Attr
Web Workshop | DHTML, HTML & CSS
layout-grid-char-spacing Attribute | layoutGridCharSpacing
Property
Sets or retrieves the character spacing used for rendering the text content of an element
with the layout-grid-type attribute set to loose.

Syntax

HTML { layout-grid-char-spacing: sCharSpace }


Scripting oObject.style.layoutGridCharSpacing [ = sCharSpace ]

Possible Values

sCharSpace String that specifies one of the following values:


auto Largest character in the font of the element is used to set the character grid.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage derived from the dimensions of the parent
object.

The property is read/write with a default value of auto; the proposed cascading style
sheets (CSS) extension attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The visual effects of the layout-grid-char-spacing attribute are similar to the


lineHeight property.

Web documents in East Asian languages, such as Chinese or Japanese, usually create a
page layout for characters using a one- or two-dimensional grid. You can use the
layout-grid attribute to incorporate this layout into Web documents.

The layout-grid-char-spacing attribute applies only to block-level elements.

Note For this property to have an effect, the layout-grid-mode attribute must be set to
char or both, and the layout-grid-type attribute must be set to loose.

Example

This example uses the layout-grid-char-spacing attribute to specify character layout


for a block of text.

<STYLE>
DIV.layout { layout-grid-char-spacing: auto }
</STYLE>
<DIV CLASS = "layout">
This is a block element containing a sentence of sample text.
</DIV>

Applies To

BLOCKQUOTE, BODY, CENTER, currentStyle, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, LI, LISTING, MARQUEE, MENU, OL, P, PLAINTEXT,
PRE, runtimeStyle, style, TABLE, TD, TH, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
layout-grid-char-spacing ... layout-grid-mode A
Web Workshop | DHTML, HTML & CSS
layout-grid-line Attribute | layoutGridLine Property
Sets or retrieves the grid line value used for rendering the text content of an element.

Syntax

HTML { layout-grid-line: sLineSpace }


Scripting oObject.style.layoutGridLine [ = sLineSpace ]

Possible Values

sLineSpace String that specifies one of the following values:


none No grid line is set.
auto Largest character in the font of the element is used to set the character grid.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage derived from the dimensions of the parent
object.

The property is read/write with a default value of none; the proposed cascading style
sheets (CSS) extension attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The visual effects of the layout-grid-line attribute are similar to the lineHeight
property.

Web documents in East Asian languages, such as Chinese or Japanese, usually create a
page layout for characters using a one- or two-dimensional grid. You can use the
layout-grid attribute to incorporate this layout into Web documents.

The layout-grid-line attribute applies only to block-level elements.

Note For this property to have an effect, the layout-grid-mode attribute must be set to
line or both.

Example

This example uses the layout-grid-line attribute to specify character layout for a
block of text.

<STYLE>
DIV.layout { layout-grid-line: auto }
</STYLE>

<DIV CLASS = "layout">


This is a block element containing a sentence of sample text.
</DIV>

Applies To

BLOCKQUOTE, BODY, CENTER, currentStyle, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, LI, LISTING, MARQUEE, MENU, OL, P, PLAINTEXT,
PRE, runtimeStyle, style, TABLE, TD, TH, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
layout-grid-line Attribut... layout-grid-type Attr
Web Workshop | DHTML, HTML & CSS
layout-grid-mode Attribute | layoutGridMode Property
Sets or retrieves whether the text layout grid uses two dimensions.

Syntax

HTML { layout-grid-mode: sMode }


Scripting oObject.style.layoutGridMode [ = sMode ]

Possible Values

sMode String that specifies one of the following values:


both Both the char and line grid modes are enabled. This setting is necessary to fully enable layout grid on an
element.
none No grid is used.
line Only a line grid is used. This is recommended for use with inline elements, such as a SPAN, to disable the
horizontal grid on runs of text that act as a single entity in the grid layout.
char Only a character grid is used. This is recommended for use with block-level elements, such as a
BLOCKQUOTE, where the line grid is intended to be disabled.

The property is read/write with a default value of both; the proposed cascading style
sheets (CSS) extension attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Web documents in East Asian languages, such as Chinese or Japanese, usually create a
page layout for characters using a one- or two-dimensional grid. You can use the
layout-grid attribute to incorporate this layout into Web documents.

Example

This example uses the layout-grid-mode attribute to specify character layout for a
block of text.

<STYLE>
DIV.layout { layout-grid-mode: line }
</STYLE>

<DIV CLASS = "layout">


This is a block element containing a sentence of sample text.
</DIV>

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE, CODE, COL,
COLGROUP, currentStyle, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn, HR, I,
IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT
type=reset, INPUT type=submit, INPUT type=text, INS, KBD, LABEL, LEGEND, LI, LISTING, MAP, MARQUEE, MENU, META, NEXTID, NOBR, OBJECT,
OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, runtimeStyle, S, SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE,
TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
layout-grid-mode Attribut... left Attribute | left
Web Workshop | DHTML, HTML & CSS
layout-grid-type Attribute | layoutGridType Property
Sets or retrieves the type of grid used for rendering the text content of an element.

Syntax

HTML { layout-grid-type: sType }


Scripting oObject.style.layoutGridType [ = sType ]

Possible Values

sType String that specifies one of the following values:


loose Grid used for Chinese (Genko) and Korean characters. Only the ideographs, kanas, and wide characters
are snapped to the grid. Other characters are rendered as usual, as though the layout-grid-mode attribute
is set to none or line for text spans containing these characters. This mode also disables special text
justification and character width adjustments normally applied to the element. Finally, if there is no line-
break opportunity in a text span that exceeds the line boundary, the text is pushed to the next line and
the last part of the previous line is left blank.
strict Grid used for Japanese characters. In this mode, a constant width increment is applied to characters as
follows:
Wide characters are incremented to obtain an exact grid fit, if no other width adjustment effect is
applied.
Narrow characters, except cursive scripts and cursive fonts, are incremented by half of the
increment amount applied to wide characters.

fixed Grid used for monospaced layout. The layout rules are as follows:
All noncursive characters are treated as equal; every character is centered within a single grid
space by default.
Runs of cursive characters are treated as strips the same way as in a strict grid.
Justification or any other character-width changing behaviors are disabled.

The property is read/write with a default value of loose; the proposed cascading style
sheets (CSS) extension attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Web documents in East Asian languages, such as Chinese or Japanese, usually create a
page layout for characters using a one- or two-dimensional grid. You can use the
layout-grid attribute to incorporate this layout into Web documents.

The layout-grid-type attribute applies only to block-level elements.

Example

This example uses the layout-grid-type attribute to specify character layout for a
block of text.

<STYLE>
DIV.layout { layout-grid-type: strict }
</STYLE>
<DIV CLASS = "layout">
This is a block element containing a sentence of sample text.
</DIV>

Applies To

BLOCKQUOTE, BODY, CENTER, currentStyle, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, LI, LISTING, MARQUEE, MENU, OL, P, PLAINTEXT,
PRE, runtimeStyle, style, TABLE, TD, TH, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
letter-spacing Attribute ... line-height Attribute
Web Workshop | DHTML, HTML & CSS
line-break Attribute | lineBreak Property
Sets or retrieves line-breaking rules for Japanese text.

Syntax

HTML { line-break : sBreak }


Scripting object.style.lineBreak [ = sBreak ]

Possible Values

sBreak String that specifies one of the following values:


normal Normal line-breaking mode is applied.
strict Stricter line-breaking rules are enforced.

The property is read/write with a default value of normal; the proposed cascading style
sheets (CSS) extension property is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Applies To

ADDRESS, BLOCKQUOTE, BODY, CENTER, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, TABLE, TD, TH, TR, UL, XMP

See Also

wordBreak

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
line-break Attribute | li... link Pseudo-class D
Web Workshop | DHTML, HTML & CSS
line-height Attribute | lineHeight Property
Sets or retrieves the distance between lines in the object.

Syntax

HTML { line-height: sHeight }


Scripting object.style.lineHeight [ = sHeight ]

Possible Values

sHeight String that specifies one of the following values:


normal Default height.
height Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the height of the parent object.

The property is read/write with a default value of normal; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Line height is the distance between the descender of the font and the top of the
internal leading of the font. A negative line height is allowed to achieve various
shadowing effects.

If a formatted line contains more than one object, the maximum line height applies. In
this case, negative values are not allowed.

Internet Explorer 3.0 supports the line-height attribute through the font attribute.

Example

The following examples use the line-height attribute and the lineHeight property to
control the height of paragraph lines.

This example uses P and BLOCKQUOTE as selectors in an embedded (global) style


sheet to change the distance between the lines in all P and BLOCKQUOTE objects.

<STYLE>
P { line-height:8mm}
BLOCKQUOTE { line-height:4mm }
</STYLE>

This feature requires Microsoft® Internet Explorer 4.0 or later. Click the icon below to
install the latest version. Then reload this page to view the sample.
This example uses inline scripting to set the distance between lines when an
onmouseover event occurs.

<DIV STYLE="font-size:14"
onmouseover="this.style.lineHeight='6mm'">
:
</DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
length Property line-break Attribute | li... DHT
Web Workshop | DHTML, HTML & CSS
letter-spacing Attribute | letterSpacing Property
Sets or retrieves the amount of additional space between letters in the object.

Syntax

HTML { letter-spacing: sSpacing }


Scripting object.style.letterSpacing [ = sSpacing ]

Possible Values

sSpacing String that specifies one of the following values:


normal Default spacing.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a relative
units designator (em or ex). For more information about the supported length units, see CSS Length
Units.

The property is read/write with a default value of normal; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

When specified as a positive length value, the letter-spacing attribute adds the
specified value to the default spacing between characters within an element. A
negative length value decreases the space between characters. Letter spacing can be
influenced by justification.

Example

The following examples use the letter-spacing attribute and the letterSpacing
property to change the space between letters.

This example uses BLOCKQUOTE as a selector to change the spacing to -0.2


millimeters for all BLOCKQUOTE objects on the page.

<STYLE>
BLOCKQUOTE { letter-spacing:-0.2mm }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the spacing to 1 millimeter when an
onmouseover event occurs.
<DIV STYLE="font-size:14"
onmouseover="this.style.letterSpacing='1mm'">
:
</DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ROWSPAN Attribute | rowSp... ruby-overhang A
Web Workshop | DHTML, HTML & CSS
ruby-align Attribute | rubyAlign Property
Sets or retrieves the position of the ruby text specified by the RT object.

Syntax

HTML { ruby-align: sRubyAlign }


Scripting object.style.rubyAlign [ = sRubyAlign ]

Possible Values

sRubyAlign String that specifies one of the following values:


auto Browser determines how the ruby text is aligned. The recommended behavior for an
ideographic (East Asian Character) ruby is to be aligned in the distribute-space mode.
The recommended behavior for a Latin character ruby is to be aligned in the center
mode.
left Ruby text is left-aligned with the base.
center Ruby text is centered within the width of the base. If the length of the base is smaller
than the length of the ruby text, the base is centered within the width of the ruby text.
right Ruby text is right-aligned with the base.
distribute-letter Ruby text is evenly distributed across the width of the base if the width of the ruby text
is smaller than the width of the base. If the width of the ruby text is at least the width of
the base, the ruby text is center-aligned.
distribute-space Ruby text is evenly distributed across the width of the base if the width of the ruby text
is smaller than the width of the base. White space precedes the first and follows the last
character in the ruby text, equal to half the kerning of the ruby text. If the width of the
ruby text is at least the width of the base, the ruby text is centered.
line-edge Ruby text is centered if it is not adjacent to a line edge. If it is adjacent to a line edge,
the side of the ruby lines up with the side of the base text.

The property is read/write with a default value of auto; the proposed cascading style
sheets (CSS) extension attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The rubyAlign property specifies the alignment of the ruby text defined by the RT
object, and is set on the RUBY object.

Example

This example uses the ruby-align attribute and the rubyAlign property to set the
alignment of the ruby text. It uses an inline style sheet to set the ruby-align attribute
to right.

<RUBY ID=oRuby STYLE = "ruby-align: right">


Ruby base.
<RT>Ruby text.
</RUBY>
<INPUT
TYPE=button VALUE="Center"
onclick="oRuby.style.rubyAlign='center';"
>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

RUBY

See Also

rubyPosition, rubyOverhang

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ruby-align Attribute | ru... ruby-position Attribu
Web Workshop | DHTML, HTML & CSS
ruby-overhang Attribute | rubyOverhang Property
Sets or retrieves the position of the ruby text specified by the RT object.

Syntax

HTML { ruby-overhang: sRubyOverhang }


Scripting object.style.rubyOverhang [ = sRubyOverhang ]

Possible Values

sRubyOverhang String that specifies one of the following values:


auto Ruby text overhangs any other text adjacent to the base text.
whitespace Ruby text overhangs only white-space characters.
none Ruby text overhangs only text adjacent to its base.

The property is read/write with a default value of auto; the proposed cascading style
sheets (CSS) extension attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The rubyOverhang property specifies the overhang of the ruby text defined by the RT
object, and is set on the RUBY object.

Example

This example uses the ruby-overhang attribute and the rubyOverhang property to
set the overhang of the ruby text. It uses an inline style sheet to set the ruby-
overhang attribute to none.

<RUBY ID=oRuby STYLE = "ruby-overhang: none">


Ruby base.
<RT>Ruby text.
</RUBY>
<INPUT
TYPE=button VALUE="Whitespace"
onclick="oRuby.style.rubyOverhang='whitespace';"
>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

RUBY
See Also

rubyAlign, rubyPosition

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ruby-overhang Attribute |... RULES Attribute |
Web Workshop | DHTML, HTML & CSS
ruby-position Attribute | rubyPosition Property
Sets or retrieves the position of the ruby text specified by the RT object.

Syntax

HTML { ruby-position: sRubyPlacement }


Scripting object.style.rubyPosition [ = sRubyPlacement ]

Possible Values

sRubyPlacement String that specifies one of the following values:


above Ruby text is positioned above the base text.
inline Ruby text is positioned inline with the base text.

The property is read/write with a default value of above; the proposed cascading style
sheets (CSS) extension attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The rubyPosition property specifies the position of the ruby text defined by the RT
object, and is set on the RUBY object.

Example

This example uses the ruby-position attribute and the rubyPosition property to set
the position of the ruby text. It uses an inline style sheet to set the ruby-position
attribute to inline.

<RUBY ID=oRuby STYLE = "ruby-position: inline">


Ruby base.
<RT>Ruby text.
</RUBY>
<P>
<INPUT
TYPE=button VALUE="Above"
onclick="oRuby.style.rubyPosition='above';"
>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

RUBY
See Also

rubyAlign, rubyOverhang

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
text Property text-autospace Attribute ... DHT
Web Workshop | DHTML, HTML & CSS
text-align Attribute | textAlign Property
Sets or retrieves whether the text in the object is left-aligned, right-aligned, centered, or
justified.

Syntax

HTML { text-align: sAlign }


Scripting object.style.textAlign [ = sAlign ]

Possible Values

sAlign String that specifies one of the following values:


left Text is aligned to the left.
right Text is aligned to the right.
center Text is centered.
justify Text is justified.

The property is read/write with a default value of left; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The justify possible value is available as of Internet Explorer 4.0.

Because this property is inherited, all block-level objects inside a DIV object having
textAlign=center are centered.

Example

This examples uses the text-align attribute and the textAlign property to align text
within the object.

This example uses P as a selector and two classes to call an embedded style sheet that
aligns the text according to the respective rule.

<STYLE>
P { text-align:center }
.align1 { text-align:right }
.align2 { text-align:justify }
</STYLE>
</HEAD>
<BODY>
<P onclick= "this.className='align1'"
ondblclick="this.className='align2'">
. . . </P>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the alignment of the text when an
onmouseover event occurs.

<P STYLE="font-size:14"
onmouseover="this.style.textAlign='center'">
. . . </P>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, CENTER, currentStyle, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, INPUT type=password, INPUT type=text, LI,
LISTING, MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, style, TABLE, TD, TEXTAREA, TH, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
text-autospace Attribute ... textDecorationBlink
Web Workshop | DHTML, HTML & CSS
text-decoration Attribute | textDecoration Property
Sets or retrieves whether the text in the object has blink, line-through, overline, or
underline decorations.

Syntax

HTML { text-decoration: sDecoration }


Scripting object.style.textDecoration [ = sDecoration ]

Possible Values

sDecoration String that specifies one or more of the following values:


none Text has no decoration.
underline Text is underlined.
overline Text has a line over it.
line-through Text has a line drawn through it.
blink Not implemented.

The property is read/write with a default value of none (see the Remarks section); the
cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The default value is different for the following tags:

Default value is underline for A when used with href, U, and INS.
Default value is line-through for STRIKE, S, and DEL.
If the value none is placed at the end of the values, all values are cleared. For
example, setting {text-decoration: underline overline blink none} causes none of
the decorations to render.

If the object has no text (for example, the IMG object in HTML) or is an empty object
(for example, "<EM> </EM>"), this property has no effect.

If you set the text-decoration attribute to none on the BODY object, the A objects
are still underlined. To remove the underline from the A objects, either set the style
inline or use A as a selector in the global style sheet.

Specifying the textDecoration property for block elements affects all inline children.
If it is specified for, or affects, an inline element, it affects all boxes generated by the
element.

The overline and blink possible values are available as of Internet Explorer 4.0.
Although blink is exposed, it is not rendered.
Example

The following examples use the text-decoration attribute and the textDecoration
property to decorate text within the object.

This example uses an inline style sheet to draw a line through the text within the
object.

<DIV STYLE="text-decoration:line-through">
:
</DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to underline the text within the SPAN object when
the user moves the mouse over the SPAN.

<SPAN STYLE="font-size:14"
onmouseover=this.style.textDecoration="underline"
:
</SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

textDecorationLineThrough, textDecorationNone, textDecorationOverline,


textDecorationUnderline

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
text-indent Attribute | t... text-transform Attrib
Web Workshop | DHTML, HTML & CSS
text-justify Attribute | textJustify Property
Sets or retrieves the type of alignment used to justify text in the object.

Syntax

HTML { text-justify: sAlign }


Scripting object.style.textJustify [ = sAlign ]

Possible Values

sAlign String that specifies one of the following values:


inter-word Aligns text by increasing spacing between words. This value's spacing behavior is the
fastest way to make all lines of text equal in length. Its justification behavior does not
affect the last line of the paragraph.
newspaper Increases or decreases spacing between letters and between words. It is the most
sophisticated form of justification for Latin alphabets.
distribute Handles spacing much like the newspaper value. This form of justification is optimized for
East Asian documents, particularly Thai.
distribute-all-lines Justifies lines in the same way as the distribute value, except that it also justifies the
last line of the paragraph. This form of justification is intended for ideographic text.
inter-ideograph Provides full justification for ideographic text. It increases or decreases both inter-
ideograph and inter-word spacing.
auto Allows the browser user agent to determine which justification algorithm to apply.

The property is read/write with a default value of auto; the proposed cascading style
sheets (CSS) extension attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

For this property to affect text layout, the text-align property must be set to justify.

Applies To

ADDRESS, BLOCKQUOTE, BODY, CENTER, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, TABLE, TD, TH, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
textDecorationUnderline P... text-justify Attribu
Web Workshop | DHTML, HTML & CSS
text-indent Attribute | textIndent Property
Sets or retrieves the indentation of the text in the object.

Syntax

HTML { text-indent: sIndent }


Scripting object.style.textIndent [ = sIndent ]

Possible Values

sIndent String that specifies one of the following values:


length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. This value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The property can be negative. An indent is not inserted in the middle of an object that
was broken by another object (such as BR in HTML).

Example

The following examples use the text-indent attribute and the textIndent property to
indent the object's text.

This example uses calls to an embedded style sheet to change the indent on the text
when an onclick event occurs. The text was originally indented 2 centimeters using DIV
as a selector in the style sheet.

<STYLE>
DIV { text-indent:2cm }
.click1 { text-indent:50% }
.click2 { text-indent: }
</STYLE>
</HEAD>
<BODY>
<DIV onclick="this.className='click1'"
ondblclick="this.className='click2'">
. . . </DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.
This example uses inline scripting to indent the text within the DIV when an
onmouseover event occurs.

<DIV onmouseover=this.style.textIndent="2cm"
:
</DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CENTER, currentStyle, DD, DFN, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, ISINDEX, LI, LISTING, MARQUEE,
MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, style, TABLE, TD, TH, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
text-justify Attribute | ... tFoot Property DHTM
Web Workshop | DHTML, HTML & CSS
text-transform Attribute | textTransform Property
Sets or retrieves the rendering of the text in the object.

Syntax

HTML { text-transform: sTransform }


Scripting object.style.textTransform [ = sTransform ]

Possible Values

sTransform String that specifies one of the following values:


none Text is not transformed.
capitalize Transforms the first character of each word to uppercase.
uppercase Transforms all the characters to uppercase.
lowercase Transforms all the characters to lowercase.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Example

The following examples use the text-transform attribute and the textTransform
property to transform a block of text from lower case to upper case when the user
moves the mouse over the text. The text transforms back to lower case when the user
clicks the text.

This example uses three calls to an embedded (global) style sheet to transform the
text.

<STYLE>
.transform1 { text-transform:uppercase }
.transform2 { text-transform:lowercase }
.transform3 { text-transform:none }
</STYLE>
</HEAD>
<BODY>
<DIV STYLE="font-size:14"
onmouseover="this.className='transform1'"
onclick= "this.className='transform2'"
ondblclick="this.className='transform3'">
:
</DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.
This example uses inline scripting to transform the text when different mouse events
occur.

<DIV STYLE="font-size:14"
onmouseover="this.style.textTransform='uppercase'"
onmouseout="this.style.textTransform='lowercase'"
onclick="this.style.textTransform='none'">
:
</DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TYPE Attribute | type Pro... uniqueID Property
Web Workshop | DHTML, HTML & CSS
unicode-bidi Attribute | unicodeBidi Property
Sets or retrieves the level of embedding with respect to the bidirectional algorithm.

Syntax

HTML { unicode-bidi:sEmbedLevel }
Scripting object.unicodeBidi [ = sEmbedLevel ]

Possible Values

sEmbedLevel String that specifies one of the following values:


normal Element does not open an additional level of embedding. For inline elements, implicit
reordering works across element boundaries.
embed Element opens an additional level of embedding. The value of the direction property
specifies the embedding level. Reordering is implicit inside the element.
bidi-override Same as the embed value, except that, inside the element, reordering is strictly in sequence
according to the direction property. This value overrides the implicit bidirectional algorithm.

The property is read/write with a default value of normal; the cascading style sheets
(CSS) attribute is inherited.

Remarks

The unicodeBidi property is used with the direction property.

The Unicode bidirectional algorithm automatically reverses embedded character


sequences according to their inherent direction. For example, the base direction of an
English document is left-to-right. If portions of a paragraph within the document
contain a language with a right-to-left reading order, the direction of that language
displays correctly right-to-left. The user agent applying the bidirectional algorithm
correctly reverses the language direction.

Applies To

A, ACRONYM, ADDRESS, AREA, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle,
custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, Hn, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT
type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, KBD,
LABEL, LEGEND, LI, LISTING, MAP, MARQUEE, MENU, NOBR, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, runtimeStyle, S, SAMP,
SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
VCARD_NAME Attribute | vc... visibility Attribut
Web Workshop | DHTML, HTML & CSS
vertical-align Attribute | verticalAlign Property
Sets or retrieves the vertical positioning of the object.

Syntax

HTML { vertical-align: sAlign }


Scripting object.style.verticalAlign [ = sAlign ]

Possible Values

sAlign String that specifies one of the following values:


baseline Aligns the contents of an object supporting VALIGN to the base line.
sub Vertically aligns the text to subscript.
super Vertically aligns the text to superscript.
top Vertically aligns the contents of an object supporting VALIGN to the top of the object.
middle Vertically aligns the contents of an object supporting VALIGN to the middle of the object.
bottom Vertically aligns the contents of an object supporting VALIGN to the bottom of the object.
text-top Vertically aligns the text of an object supporting VALIGN to the top of the object.
text-bottom Vertically aligns the text of an object supporting VALIGN to the bottom of the object.

The property is read/write with a default value of baseline; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The values sub and super are supported on text. The other values are supported for
objects that support VALIGN.

Example

This example uses of the verticalAlign property to align text within a table cell.

<TABLE BORDER width=100>


<TR>
<TD onmouseover="this.style.verticalAlign='bottom'"
onmouseout="this.style.verticalAlign=''">
text to align</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

COL, currentStyle, custom, IMG, runtimeStyle, SPAN, style, TBODY, TD, TFOOT, TH, THEAD, TR
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
width Attribute | width P... word-spacing Attribu
Web Workshop | DHTML, HTML & CSS
word-break Attribute | wordBreak Property
Sets or retrieves line-breaking behavior within words, particularly where multiple
languages appear in the object.

Syntax

HTML { word-break:sBreak }
Scripting object.style.wordBreak [ = sBreak ]

Possible Values

sBreak String that specifies one of the following values:


normal Allows line breaking within words.
break-all Behaves the same as normal for Asian text, yet allows the line to break arbitrarily for non-Asian text.
This value is suited to Asian text that contains some excerpts of non-Asian text.
keep-all Does not allow word breaking for Chinese, Japanese, and Korean. Functions the same way as normal
for all non-Asian languages. This value is optimized for text that includes small amounts of Chinese,
Japanese, or Korean.

The property is read/write with a default value of normal; the proposed cascading style
sheets (CSS) extension attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Applies To

ADDRESS, BLOCKQUOTE, BODY, CENTER, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, HR, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, TABLE, TD, TH, TR, UL, XMP

See Also

lineBreak

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
word-break Attribute | wo... WRAP Attribute | w
Web Workshop | DHTML, HTML & CSS
word-spacing Attribute | wordSpacing Property
Sets or retrieves the amount of additional space between words in the object.

Syntax

HTML { word-spacing: sSpacing }


Scripting object.style.wordSpacing [ = sSpacing ]

Possible Values

sSpacing String that specifies one of the following values:


normal Default spacing.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a relative
units designator (em or ex). For more information about the supported length units, see CSS Length
Units.

The property is read/write with a default value of normal; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The word-spacing attribute is available only on the Macintosh, beginning with


Internet Explorer 4.01.

The attribute adds the specified spacing after each word. Justification can influence
word spacing.

The length value indicates an addition to the default space between words. Negative
values are permitted.

Example

This example uses the word-spacing attribute and the wordSpacing property to
increase the amount of space between words in a SPAN.

<STYLE>
SPAN.spacing{word-spacing: 10;}
</STYLE>

<SCRIPT>
function fnChangeSpace(){
oSpan.style.wordSpacing =
oSelSpace.options[oSelSpace.selectedIndex].text;
}
</SCRIPT>
<SELECT ID = "oSelSpace" onchange = "fnChangeSpace()">
<OPTION>10
<OPTION>15
<OPTION>20
</SELECT>
<SPAN ID = "oSpan" CLASS = "spacing">
The quick brown fox jumped over the lazy dog.
</SPAN>

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD, DFN, DIR, DIV, DL, DT, EM,
FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password,
INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL,
VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
availWidth Property BACKGROUND Attribute | b
Web Workshop | DHTML, HTML & CSS
background Attribute | background Property
Sets or retrieves up to five separate background properties of the object.

Syntax

HTML { background: sBackground }


Scripting object.style.background [ = sBackground ]

Possible Values

sBackground String that specifies up to five of the following space-delimited values, in any order:
color Any of the range of color values available to the backgroundColor property.
image Any of the range of image values available to the backgroundImage property.
repeat Any of the range of repeat values available to the backgroundRepeat property.
attachment Any of the range of attachment values available to the backgroundAttachment property.
position Any of the range of position values available to the backgroundPosition property.

The property is read/write with a default value of transparent none repeat scroll
0% 0%. The cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The background property is a composite property. Separate properties can be used to


specify each of the individual properties, but in many cases it is more convenient to set
them in one place using this composite property.

Individual background properties not set by the composite background property are
set to their default values. For example, the default value for image is none. Setting
background: white is equivalent to setting background: white none repeat scroll
0% 0%. So, in addition to setting the background color to white, setting background:
white clears any image, repeat, attachment, or position values previously set.

The background properties render in the object's content and padding; however,
borders are set using the border properties.

In Microsoft® Internet Explorer 3.0, elements that expose the background property
only support the color and image values; the attachment value is only supported by
the BODY, TABLE, and TD elements. In block elements, such as P and DIV, background
images and colors appear only behind text in Internet Explorer 3.0; in Internet
Explorer 4.0 and later, backgrounds stretch from margin to margin when used with
block elements.

Although objects do not inherit the background property, the background image or
color of an object's parent appears behind an object if a background is not specified.
For more information about supported colors, see the Color Table.

Example

The following examples use the background property and the background attribute
to set the background values.

This example uses inline event handlers to modify the background-color and
background-position attributes of an image. These attributes are specified in an
embedded style sheet using the background attribute.

<STYLE>
.style1{background:beige url(sphere.jpg) no-repeat top center}
.style2{background:ivory url(sphere.jpeg) no-repeat bottom
right}
</STYLE>
</HEAD>
<BODY>
<SPAN onmouseover="this.className='style1'"
onmouseout="this.className='style2'">
. . . </SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to modify the backgroundColor and


backgroundPosition properties of an image.

<SPAN onclick="this.style.background='beige url(sphere.jpeg)


no-repeat top center'">
. . . </SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD, DFN, DIR, DIV, DL, DT, EM,
FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password,
INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH,
THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BACKGROUND Attribute | ba... background-colo
Web Workshop | DHTML, HTML & CSS
background-attachment Attribute | backgroundAttachment
Property
Sets or retrieves how the background image is attached to the object within the document.

Syntax

HTML { background-attachment: sAttachment }


Scripting object.style.backgroundAttachment [ = sAttachment ]

Possible Values

sAttachment String that specifies one of the following values:


scroll Background image scrolls with the object as the document is scrolled.
fixed Background image stays fixed within the viewable area of the object.

The property is read/write with a default value of scroll; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This property can be set with the other background properties by using the
background composite property.

Microsoft® Internet Explorer 3.0 supports the background-attachment attribute, but


only when it's set by using the background attribute.

Example

The following examples use the background-attachment attribute and the


backgroundAttachment property to set the background to "fixed", so that the
background does not scroll with the text.

This example uses an inline style sheet to set the background to fixed.

<STYLE >
BODY { background-attachment:fixed }
</STYLE>
</HEAD>
<BODY background="some.jpg">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the background to fixed.


<BODY ID="oBdy" background="marble05.jpg"
onload="oBdy.style.backgroundAttachment = 'fixed'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BODY, currentStyle, HTML, runtimeStyle, style

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
background-attachment Att... background-imag
Web Workshop | DHTML, HTML & CSS
background-color Attribute | backgroundColor Property
Sets or retrieves the color behind the content of the object.

Syntax

HTML { background-color: sColor }


Scripting object.style.backgroundColor [ = sColor ]

Possible Values

sColor String that specifies one of the following values:


transparent Color of the next parent object through which the background is visible.
color Any color value, including those specified in the Color Table.

The property is read/write with a default value of transparent; the cascading style
sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This property can be set with the other background properties by using the
background composite property.

Internet Explorer 3.0 supports the background-color attribute, but only when it's set
by using the background attribute.

Windows CE

In Microsoft® Windows® CE, specifying a value for the backgroundColor property of


the OPTION element when applied through the style object has no effect.

Example

The following examples use the background-color attribute and the


backgroundColor property to specify the background color.

This example uses an inline style sheet to set the background color to beige.

<SPAN STYLE="font-size:14; background-color:beige">


. . . </SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the background color to beige.
<SPAN onmouseover="this.style.backgroundColor='beige'">
. . . </SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, OPTION, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE,
TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
background-color Attribut... background-positio
Web Workshop | DHTML, HTML & CSS
background-image Attribute | backgroundImage Property
Sets or retrieves the background image of the object.

Syntax

HTML { background-image: sLocation }


Scripting object.style.backgroundImage [ = sLocation ]

Possible Values

sLocation String that specifies one of the following values:


none Color of the next parent through which the background is visible.
url(sUrl) Location of the background image, where sUrl is an absolute or relative URL.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The URL identifies the image file. When setting a background image, you can set a
background color to be used when the image is unavailable. When the image is
available, it overlays the background color.

This property may be set with other background properties by using the background
composite property.

Internet Explorer 3.0 supports the background-image attribute, but only when it's
set through the background attribute.

Example

The following examples use the background-image attribute and the


backgroundImage property to specify the background's image.

This example uses a call to an embedded (global) style sheet to show and hide the
background image.

<STYLE>
.setUrl { background-image: url(sphere.jpg) }
.loseUrl { background-image: url(none) }
</STYLE>
</HEAD>
<BODY>
<SPAN STYLE="font-size:14" onmouseover="this.className='setUrl'"
onmouseout="this.className='loseUrl'">
. . . </SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to show and hide the background image.

<SPAN
onmouseover="this.style.backgroundImage='url(sphere.jpeg)'">
. . . </SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
background-image Attribut... backgroundPositio
Web Workshop | DHTML, HTML & CSS
background-position Attribute | backgroundPosition Property
Sets or retrieves the position of the background of the element.

Syntax

HTML { background-position: sPosition }


Scripting object.style.backgroundPosition [ = sPosition ]

Possible Values

sPosition String that specifies one or two of the following values:


length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage of the width or height of the object.
vAlignment Vertical alignment value consisting of one of the following:

top Vertical alignment is at the top.


center Vertical alignment is centered.
bottom Vertical alignment is at the bottom.
hAlignment Horizontal alignment value consisting of one of the following:

left Horizontal alignment is to the left.


center Horizontal alignment is centered.
right Horizontal alignment is to the right.

The property is read/write with a default value of 0% 0%; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

If only one value is set, that value applies to the horizontal coordinate, and the vertical
is set to 50%. If both values are set, the first value applies to the horizontal coordinate
and the second value applies to the vertical.

Setting the values to 0% 0% positions the background-image to the upper left corner of
the element's content excluding the padding.

Specifying right center has the following effect: Because right is assumed to be an
x-coordinate direction, right will overwrite the center value; the background shifts
right accordingly.

This property may be set together with the other background properties using the
background composite property.

Example
The following examples use the background-position attribute and the
backgroundPosition property to specify the position of a background image.

This example uses a call to an embedded (global) style sheet to move the sphere.

<STYLE>
.style1 { background-position:top center }
.style2 { background-position:bottom right }
</STYLE>
</HEAD>
<BODY onload="oSpan.className='style1'">
<SPAN STYLE="font-size:14; width:250;" ID="oSpan"
onmouseover="this.className='style2'"
onmouseout="this.className='style1'">
. . . </SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses an inline style to move the sphere.

<SPAN onmouseover="this.style.backgroundPosition='bottom
right'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD, DFN, DIR, DIV, DL, DT, EM,
FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password,
INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH,
THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
backgroundPositionY Prope... BALANCE Attribut
Web Workshop | DHTML, HTML & CSS
background-repeat Attribute | backgroundRepeat Property
Sets or retrieves how the backgroundImage property of the object is tiled.

Syntax

HTML { background-repeat: sRepeat }


Scripting object.style.backgroundRepeat [ = sRepeat ]

Possible Values

sRepeat String that specifies one of the following values:


repeat Image is repeated horizontally and vertically.
no-repeat Image is not repeated.
repeat-x Image is repeated horizontally.
repeat-y Image is repeated vertically.

The property is read/write with a default value of repeat; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The repeat-x and repeat-y values make the image repeat horizontally and vertically,
respectively, creating a single band of images from one side to the other.

This property can be set with other background properties by using the background
composite property.

Example

The following examples use the background-repeat attribute and the


backgroundRepeat property to specify whether the background image is tiled.

This example uses a call to an embedded (global) style sheet to tile the image.

<STYLE>
.style1 { background-image:url(sphere.jpg);
background-repeat:repeat }
.style2 { background-image:url(sphere.jpeg);
background-repeat:no-repeat }
</STYLE>
</HEAD>
<BODY>
<SPAN onmouseover="this.className='style1'"
onmouseout="this.className='style2'"
onclick="this.className=''">
. . . </SPAN>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example shows how to use inline scripting to tile the image.

<SPAN
onmouseover="this.style.backgroundImage='url(sphere.jpeg)';
this.style.backgroundRepeat='repeat'">
:
</SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
COLOR Attribute | color P... colorDepth Property
Web Workshop | DHTML, HTML & CSS
color Attribute | color Property
Sets or retrieves the color of the text of the object.

Syntax

HTML { color : sColor }


Scripting object.style.color [ = sColor ]

Possible Values

sColor String that specifies one of the color names or red-green-blue (RGB) values in the Color Table.

The property is read/write with no default value; the cascading style sheets (CSS)
attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

These are different ways to specify a color—in this example, red.

EM { color: red } /* natural language / CNS */


EM { color: #F00 } /* #RGB */
EM { color: #FF0000 } /* #RRGGBB */
EM { color: rgb 1.0 0.0 0.0 } /* float range: 0.0 - 1.0 */

Some browsers do not recognize color names, but all browsers should recognize red-
green-blue (RGB) color values and display them correctly.

Windows CE

In Microsoft® Windows® CE, specifying a value for the color property of the OPTION
element when applied through the style object has no effect.

Example

The following examples use the color attribute and the color property to change the
text color of an object.

This example uses a call to an embedded (global) style sheet to change the text color
to red when an onmouseover event occurs.

<STYLE>
.color1 { color:red }
.color2 { color: }
</STYLE>
</HEAD>
<BODY>
<SPAN STYLE="font-size:14" onmouseover="this.className='color1'"
onmouseout="this.className='color2'"> . . .

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the text color to red when an
onmouseover event occurs.

<SPAN STYLE="font-size:14" onmouseover="this.style.color='red'">


:
</SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN,
DIR, DIV, DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OL, OPTION, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE,
TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BGPROPERTIES Attribute | ... BORDER Attribute
Web Workshop | DHTML, HTML & CSS
border Attribute | border Property
Sets or retrieves the properties to be drawn around the object.

Syntax

HTML { border: sBorder }


Scripting object.style.border [ = sBorder] ]

Possible Values

sBorder String that specifies one or more of the following space-delimited values:
width Any of the range of width values available to the borderWidth property.
style Any of the range of style values available to the borderStyle property.
color Any of the range of color values available to the borderColor property.

The property is read/write with a default value of medium none; the cascading style
sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The border property is a composite property that sets the width, style, and color
values for all four sides of an object.

You must specify a style when specifying a width and/or color; otherwise, the border
does not render.

All individual border properties not set by the composite border property are set to
their default values. For example, the default value for width is medium.

The setting border=thin is identical to border=thin none; the default value for the
border color is the same as the text color if one is not initially set. So, not only does
the property set width to thin, it also clears any style or color values previously set.

Setting a border to zero or omitting the attribute causes no border to be displayed.


Supplying the border attribute without a value defaults to a single border.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

If a color is not specified, the text color is used.

For more information about supported colors, see the Color Table.

Example
The following examples use the border attribute and the border property to specify
the composite border properties.

This example uses a call to an embedded (global) style sheet to modify the border
attribute.

<HEAD>
<STYLE>
.applyBorder { border:0.2cm groove orange }
.removeBorder { border:none }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='applyBorder'"
onmouseout="this.className='removeBorder'">
<IMG src="sphere.jpg"></TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to modify the border property.

<TD onmouseover="this.style.border='0.2cm groove pink'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, IFRAME, IMG, INPUT
type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT
type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE, TD,
TEXTAREA, TH, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
BORDER Attribute | border... border-bottom-co
Web Workshop | DHTML, HTML & CSS
border-bottom Attribute | borderBottom Property
Sets or retrieves the properties of the bottom border of the object.

Syntax

HTML { border-bottom: sBottom }


Scripting object.style.borderBottom [ = sBottom ]

Possible Values

sBottom String that specifies one or more of the following space-delimited values:
width Any of the range of width values available to the borderBottomWidth property.
style Any of the range of style values available to the borderBottomStyle property.
color Any of the range of color values available to the borderBottomColor property.

The property is read/write with a default value of medium none; the cascading style
sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The borderBottom property is a composite property that sets the width, color, and
style values for the bottom border of an object.

All individual border properties not set by the composite borderBottom property are
set to their default values. For example, the default value for width is medium.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

If a color is not specified, the text color is used.

For more information about supported colors, see the Color Table.

Example

The following examples use the borderBottom property and the border-bottom
attribute to specify the various properties for the bottom border.

This example uses a call to an embedded (global) style sheet to change the attributes
of the bottom border.

<HEAD>
<STYLE>
TD { border-bottom:0.5cm solid yellow }
.change { border-bottom:0.5cm groove pink }
</STYLE>
</HEAD>
<BODY>
<TABLE>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''"><IMG src="sphere.jpg"></TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the bottom border.

<TD onmouseover="this.style.borderBottom='0.3cm groove yellow'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG, INPUT
type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT
type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE, TD,
TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-bottom Attribute |... border-bottom-sty
Web Workshop | DHTML, HTML & CSS
border-bottom-color Attribute | borderBottomColor Property
Sets or retrieves the color of the bottom border of the object.

Syntax

HTML { border-bottom-color: sColor }


Scripting object.style.borderBottomColor [ = sColor ]

Possible Values

sColor String that specifies one of the color names or red-green-blue (RGB) values in the Color Table.

The property is read/write with a default value equal to the value of the color property;
the cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Some browsers do not recognize color names, but all browsers should recognize RGB
color values and display them correctly.

Example

The following examples use the border-bottom-color attribute and the


borderBottomColor property to specify the border color.

This example uses a call to an embedded (global) style sheet to change the color of
the bottom border.

<HEAD>
<STYLE>
TD { border-bottom-color: red;
border-width: 0.5cm; border-style: groove}
.blue { border-bottom-color: blue}
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
TD onmouseover="this.className='blue'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the color of the bottom border.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderBottomColor='blue'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

currentStyle, border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-bottom-color Attri... border-bottom-wid
Web Workshop | DHTML, HTML & CSS
border-bottom-style Attribute | borderBottomStyle Property
Sets or retrieves the style of the bottom border of the object.

Syntax

HTML { border-bottom-style: sStyle }


Scripting object.style.borderBottomStyle [ = sStyle ]

Possible Values

sStyle String that specifies one of the following values:


none Border is not drawn, regardless of any border-width.
dotted Border is a dotted line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
dashed Border is a dashed line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
solid Border is a solid line.
double Border is a double line drawn on top of the background of the object. The sum of the two single lines and
the space between equals the border-width value. The border width must be at least 3 pixels wide to draw
a double border.
groove 3-D groove is drawn in colors based on the value.
ridge 3-D ridge is drawn in colors based on the value.
inset 3-D inset is drawn in colors based on the value.
outset 3-D outset is drawn in colors based on the value.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

A border-width greater than 0 must be set for the border-bottom-style attribute to


render.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Example

The following examples use the border-bottom-style attribute and the


borderBottomStyle property to specify the border style.

This example uses a call to an embedded style sheet to change the style of the bottom
border to groove.

<HEAD>
<STYLE>
TD { border-bottom-style:solid;
border-width=0.3cm }
.change { border-bottom-style:groove}
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the style of the bottom border to groove.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderBottomStyle='groove'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-bottom-style Attri... border-collapse Att
Web Workshop | DHTML, HTML & CSS
border-bottom-width Attribute | borderBottomWidth Property
Sets or retrieves the width of the bottom border of the object.

Syntax

HTML { border-bottom-width: sWidth }


Scripting object.style.borderBottomWidth [ = sWidth ]

Possible Values

sWidth String that specifies one of the following values:


medium Default width.
thin Less than the default width.
thick Greater than the default width.
width Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a relative
units designator (em or ex). For more information about the supported length units, see CSS Length
Units.

The property is read/write with a default value of medium; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must either have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

The property is supported on block and replaced objects only.

Example

The following examples use the border-bottom-width attribute and the


borderBottomWidth property to specify the border width.

This example uses a call to an embedded (global) style sheet to change the width of
the bottom border to 1 centimeter when a mouse click occurs.

<HEAD>
<STYLE>
TD { border-bottom-width:3mm }
.changeborder1 { border-bottom-width:1cm }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onclick="this.className='changeborder1'"
ondblclick="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the width of the bottom border to 1
centimeter when a mouse click occurs.

<TD onclick="this.style.borderBottomWidth='1cm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-bottom-width Attri... border-color Attrib
Web Workshop | DHTML, HTML & CSS
border-collapse Attribute | borderCollapse Property
Sets or retrieves a value indicating whether the row and cell borders of a table are joined
into a single border or detached as in standard HTML.

Syntax

HTML { border-collapse : sCollapse }


Scripting table.style.borderCollapse [ = sCollapse ]

Possible Values

sCollapse String that specifies one of the following values:


separate Borders are detached (standard HTML).
collapse Borders are collapsed, where adjacent, into a single border.

The property is read/write with a default value of separate; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Example

This example demonstrates how to use the border-collapse attribute and the
borderCollapse property to manipulate the border on a table.

<TABLE ID=oTable STYLE="border-collapse:collapse">


<TR><TD>EST</TD><TD>9:00 a.m.</TD></TR>
<TR><TD>CST</TD><TD>8:00 a.m.</TD></TR>
<TR><TD>PST</TD><TD>6:00 a.m.</TD></TR>
</TABLE>

<P>
<INPUT TYPE=button
onclick="oTable.style.borderCollapse='separate'"
VALUE="separate">
<INPUT TYPE=button
onclick="oTable.style.borderCollapse='collapse'"
VALUE="collapse">

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

TABLE
See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-collapse Attribute... BORDERCOLOR Attr
Web Workshop | DHTML, HTML & CSS
border-color Attribute | borderColor Property
Sets or retrieves the border color of the object.

Syntax

HTML { border-color: sColor }


Scripting object.style.borderColor [ = sColor ]

Possible Values

sColor String that specifies up to four color names or red-green-blue (RGB) values in the Color Table.

The property is read/write with a default value equal to the value of the color property;
the cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Up to four different colors can be specified in the following order: top, right, bottom,
left. If one color is supplied, it is used for all four sides. If two colors are supplied, the
first is used for the top and bottom, and the second is used for left and right. If three
colors are supplied, they are used for top, right and left, and bottom, respectively.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

The borderColor property does not render if the borderStyle property is set to none.

The property is supported on block and replaced objects only.

Some browsers do not recognize color names, but all browsers should recognize RGB
color values and display them correctly.

Example

The following examples use the border-color attribute and the borderColor property
to specify the border color.

This example uses a call to an embedded (global) style sheet to change the color of
the border to blue from an initial value of red when the mouse moves over the image.

<HEAD>
<STYLE>
TD { border-color: red; border-width: 0.5cm }
.blue { border-color: blue }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='blue'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the color of the border to blue when the
mouse moves over the image.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderColor='blue';
this.style.borderStyle='solid'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
borderColorLight Property border-left-color Attr
Web Workshop | DHTML, HTML & CSS
border-left Attribute | borderLeft Property
Sets or retrieves the properties of the left border of the object.

Syntax

HTML { border-left: sLeft }


Scripting object.style.borderLeft [ = sLeft ]

Possible Values

sLeft String that specifies one or more of the following space-delimited values:
width Any of the range of width values available to the borderLeftWidth property.
style Any of the range of style values available to the borderLeftStyle property.
color Any of the range of color values available to the borderLeftColor property.

The property is read/write with a default value of medium none; the cascading style
sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The borderLeft property is a composite property that sets the width, color, and style
values for the left border of an object.

All individual border properties not set by the composite borderLeft property are set
to their default values. For example, the default value for width is medium.

If the color value is not specified, the text color is used.

For more information about supported colors, see the Color Table.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Example

The following examples use the borderLeft property and the border-left attribute to
specify the composite border-left properties.

This example uses a call to an embedded (global) style sheet to modify the attributes
of the left border.

<HEAD>
<STYLE>
TD { border-left:0.5cm solid yellow }
.change { border-left:0.5cm groove pink }
</STYLE>
</HEAD>
<BODY>
<TABLE>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the properties of the left border.

<TD onmouseover="this.style.borderLeft='0.3cm groove yellow'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG, INPUT
type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT
type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE, TD,
TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-left Attribute | b... border-left-style Attr
Web Workshop | DHTML, HTML & CSS
border-left-color Attribute | borderLeftColor Property
Sets or retrieves the color of the left border of the object.

Syntax

HTML { border-left-color: sColor }


Scripting object.style.borderLeftColor [ = sColor ]

Possible Values

sColor String that specifies one of the color names or red-green-blue (RGB) values in the Color Table.

The property is read/write with a default value equal to the value of the color property;
the cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Some browsers do not recognize color names, but all browsers should recognize RGB
color values and display them correctly.

Example

The following examples use the border-left-color attribute and the borderLeftColor
property to specify the color of the left border.

This example uses a call to an embedded (global) style sheet to change the color of
the left border from red to blue when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-left-color: red;
border-width: 0.5cm; border-style: groove}
.blue { border-left-color: blue}
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='blue'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the color of the left border from red to
blue when an onmouseover event occurs.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderLeftColor='blue'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-left-color Attribu... border-left-width Att
Web Workshop | DHTML, HTML & CSS
border-left-style Attribute | borderLeftStyle Property
Sets or retrieves the style of the left border of the object.

Syntax

HTML { border-left-style: sStyle }


Scripting object.style.borderLeftStyle [ = sStyle ]

Possible Values

sStyle String that specifies one of the following values:


none No border is drawn, regardless of any specified border-width.
dotted Border is a dotted line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
dashed Border is a dashed line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
solid Border is a solid line.
double Border is a double line drawn on top of the background of the object. The sum of the two single lines and
the space between equals the border-width value. The border width must be at least 3 pixels wide to draw
a double border.
groove 3-D groove is drawn in colors based on the value.
ridge 3-D ridge is drawn in colors based on the value.
inset 3-D inset is drawn in colors based on the value.
outset 3-D outset is drawn in colors based on the value.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

A border-width greater than 0 must be set for the border-left-style attribute to


render.

Inline elements must have an absolute position or layout to use this property.
Element layout is set by providing a value for the height property or the width
property.

Example

The following examples use the border-left-style attribute and the borderLeftStyle
property to specify the style of the left border.

This example uses a call to an embedded (global) style sheet to change the style of
the left border from solid to groove when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-left-style:solid; border-width=0.3cm }
.change { border-left-style:groove }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the style of the left border to groove
when an onmouseover event occurs.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderLeftStyle='groove'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-left-style Attribu... border-right Attribut
Web Workshop | DHTML, HTML & CSS
border-left-width Attribute | borderLeftWidth Property
Sets or retrieves the width of the left border of the object.

Syntax

HTML { border-left-width: sWidth }


Scripting object.style.borderLeftWidth [ = sWidth ]

Possible Values

sWidth String that specifies one of the following values:


medium Default width.
thin Less than the default width.
thick Greater than the default width.
width Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a relative
units designator (em or ex). For more information about the supported length units, see CSS Length
Units.

The property is read/write with a default value of medium; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must either have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

The property is supported on block and replaced objects only.

Example

The following examples use the border-left-width attribute and the


borderLeftWidth property to specify the border width.

This example uses a call to an embedded (global) style sheet to change the width of
the left border width to 1 centimeter when a mouse click occurs.

<HEAD>
<STYLE>
TD { border-left-width:3mm }
.changeborder1 { border-left-width:1cm }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onclick="this.className='changeborder1'"
ondblclick="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR></TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the width of the left border width to 1
centimeter when a mouse click occurs.

<TD onclick="this.style.borderLeftWidth='1cm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border, borderWidth

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-left-width Attribu... border-right-color A
Web Workshop | DHTML, HTML & CSS
border-right Attribute | borderRight Property
Sets or retrieves the properties of the right border of the object.

Syntax

HTML { border-right: sRight }


Scripting object.style.borderRight [ = sRight] ]

Possible Values

sRight String that specifies one or more of the following space-delimited values:
width Any of the range of width values available to the borderRightWidth property.
style Any of the range of style values available to the borderRightStyle property.
color Any of the range of color values available to the borderRightColor property.

The property is read/write with a default value of medium none; the cascading style
sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The borderRight property is a composite property that sets the width, color, and style
values for the right border of an object.

All individual border properties not set by the composite borderRight property are set
to their default values. For example, the default value for width is medium.

If a color is not specified, the text color is used.

For more information about supported colors, see the Color Table.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Example

The following examples use the borderRight property and the border-right attribute
to specify the composite properties.

This example uses a call to an embedded (global) style sheet to change the attributes
of the right border when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-right:0.5cm solid yellow }
.change { border-right:0.5cm groove pink }
</STYLE>
</HEAD>
<BODY>
<TABLE>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''">
<IMG src="sphere.jpg"></TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the attributes of the right border when an
onmouseover event occurs.

<TD onmouseover="this.style.borderRight='0.3cm groove yellow'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG, INPUT
type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT
type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE, TD,
TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-right Attribute | ... border-right-style At
Web Workshop | DHTML, HTML & CSS
border-right-color Attribute | borderRightColor Property
Sets or retrieves the color of the right border of the object.

Syntax

HTML { border-right-color: sColor }


Scripting object.style.borderRightColor [ = sColor ]

Possible Values

sColor String that specifies one of the color names or red-green-blue (RGB) values in the Color Table.

The property is read/write with a default value equal to the value of the color property;
the cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Some browsers do not recognize color names, but all browsers should recognize RGB
color values and display them correctly.

Example

The following examples use the border-right-color attribute and the


borderRightColor property to specify the color of the right border.

This example uses a call to an embedded (global) style sheet to change the color of
the right border from red to blue when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-right-color: red;
border-width: 0.5cm; border-style: groove}
.blue { border-right-color: blue }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='blue'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the color of the right border to blue when
an onmouseover event occurs.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderRightColor='blue';>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-right-color Attrib... border-right-width A
Web Workshop | DHTML, HTML & CSS
border-right-style Attribute | borderRightStyle Property
Sets or retrieves the style of the right border of the object.

Syntax

HTML { border-right-style: sStyle }


Scripting object.style.borderRightStyle [ = sStyle ]

Possible Values

sStyle String that specifies one of the following values:


none No border is drawn, regardless of any specified border-width.
dotted Border is a dotted line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
dashed Border is a dashed line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
solid Border is a solid line.
double Border is a double line drawn on top of the background of the object. The sum of the two single lines and
the space between equals the border-width value. The border width must be at least 3 pixels wide to draw
a double border.
groove 3-D groove is drawn in colors based on the value.
ridge 3-D ridge is drawn in colors based on the value.
inset 3-D inset is drawn in colors based on the value.
outset 3-D outset is drawn in colors based on the value.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

A border-width greater than 0 must be set for the border-right-style attribute to


render.

Example

The following examples use the border-right-style attribute and the


borderRightStyle property to specify the border style.

This example uses a call to an embedded (global) style sheet to change the style of
the right border from solid to groove when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-right-style:solid; border-width=0.3cm }
.change { border-right-style:groove }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the style of the right border to groove
when an onmouseover event occurs.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderRightStyle='groove'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-right-style Attrib... border-style Attribut
Web Workshop | DHTML, HTML & CSS
border-right-width Attribute | borderRightWidth Property
Sets or retrieves the width of the right border of the object.

Syntax

HTML { border-right-width: sWidth }


Scripting object.style.borderRightWidth [ = sWidth ]

Possible Values

sWidth String that specifies one of the following values:


medium Default width.
thin Less than the default width.
thick Greater than the default width.
width Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a relative
units designator (em or ex). For more information about the supported length units, see CSS Length
Units.

The property is read/write with a default value of medium; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must either have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

The property is supported on block and replaced objects only.

Example

The following examples use the border-right-width attribute and the


borderRightWidth property to specify the width of the right border.

This example uses a call to an embedded (global) style sheet to change the width of
the right border to 1 centimeter when a mouse click occurs.

<HEAD>
<STYLE>
TD { border-right-width:3mm }
.changeborder1 { border-right-width:1cm }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onclick="this.className='changeborder1'"
ondblclick="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR></TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline script to change the width of the right border to 1 centimeter
when a mouse click occurs.

<TD onclick="this.style.borderRightWidth='1cm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border, borderWidth

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-right-width Attrib... border-top Attribute
Web Workshop | DHTML, HTML & CSS
border-style Attribute | borderStyle Property
Sets or retrieves the style of the left, right, top, and bottom borders of the object.

Syntax

HTML { border-style: sStyle }


Scripting object.style.borderStyle [ = sStyle ]

Possible Values

sStyle String that specifies one of the following values:


none No border is drawn, regardless of any specified border-width.
dotted Border is a dotted line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
dashed Border is a dashed line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
solid Border is a solid line.
double Border is a double line drawn on top of the background of the object. The sum of the two single lines and
the space between equals the border-width value. The border width must be at least 3 pixels wide to draw
a double border.
groove 3-D groove is drawn in colors based on the value.
ridge 3-D ridge is drawn in colors based on the value.
inset 3-D inset is drawn in colors based on the value.
outset 3-D outset is drawn in colors based on the value.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

A border-width greater than 0 must be set for the border-style attribute to render.

Example

The following examples use the border-style attribute and the borderStyle property
to specify the border style.

This example uses a call to an embedded (global) style sheet to change the style of
the border to groove when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-style:solid; border-width=0.5cm }
.change { border-style:groove }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the style of the border to groove when an
onmouseover event occurs.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderStyle='groove'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-style Attribute | ... border-top-color Attr
Web Workshop | DHTML, HTML & CSS
border-top Attribute | borderTop Property
Sets or retrieves the properties of the top border of the object.

Syntax

HTML { border-top: sTop }


Scripting object.style.borderTop [ = sTop ]

Possible Values

sTop String that specifies one or more of the following space-delimited values:
width Any of the range of width values available to the borderTopWidth property.
style Any of the range of style values available to the borderTopStyle property.
color Any of the range of color values available to the borderTopColor property.

The property is read/write with a default value of medium none; the cascading style
sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The borderTop property is a composite property that sets the width, color, and style
values for the top border of an object.

All individual border properties not set by the composite borderTop property are set
to their default values. For example, the default value for width is medium.

If a color is not specified, the text color is used.

For more information about supported colors, see the Color Table.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Example

The following examples use the border-top attribute and the borderTop property to
specify the composite properties.

This example uses a call to an embedded (global) style sheet to change the attributes
of the top border when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-top:0.5cm solid yellow }
.change { border-top:0.5cm groove pink }
</STYLE>
</HEAD>
<BODY>
<TABLE>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the top border when an onmouseover
event occurs.

<TD onmouseover="this.style.borderTop='0.3cm groove yellow'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG, INPUT
type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT
type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE, TD,
TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-top Attribute | bo... border-top-style Att
Web Workshop | DHTML, HTML & CSS
border-top-color Attribute | borderTopColor Property
Sets or retrieves the color of the top border of the object.

Syntax

HTML { border-top-color: sColor }


Scripting object.style.borderTopColor [ = sColor ]

Possible Values

sColor String that specifies one of the color names or red-green-blue (RGB) values in the Color Table.

The property is read/write with a default value equal to the value of the color property;
the cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Some browsers do not recognize color names, but all browsers should recognize RGB
color values and display them correctly.

Example

The following examples use the border-top-color attribute and the borderTopColor
property to specify the color of the top border.

This example uses a call to an embedded (global) style sheet to change the color of
the top border to blue when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-top-color: red;
border-width: 0.5cm; border-style: groove }
.blue { border-top-color: blue }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='blue'"
onmouseout="this.className=''">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the color of the top border to blue when
an onmouseover event occurs.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderTopColor='blue'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-top-color Attribut... border-top-width At
Web Workshop | DHTML, HTML & CSS
border-top-style Attribute | borderTopStyle Property
Sets or retrieves the style of the top border of the object.

Syntax

HTML { border-top-style: sStyle }


Scripting object.style.borderTopStyle [ = sStyle ]

Possible Values

sStyle String that specifies one of the following values:


none No border is drawn, regardless of any specified border-width.
dotted Border is a dotted line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
dashed Border is a dashed line on the Macintosh platform as of Internet Explorer 4.01, and a solid line on the
Windows and Unix platforms.
solid Border is a solid line.
double Border is a double line drawn on top of the background of the object. The sum of the two single lines and
the space between equals the border-width value. The border width must be at least 3 pixels wide to draw
a double border.
groove 3-D groove is drawn in colors based on the value.
ridge 3-D ridge is drawn in colors based on the value.
inset 3-D inset is drawn in colors based on the value.
outset 3-D outset is drawn in colors based on the value.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

A border-width greater than 0 must be set for the border-top-style attribute to


render.

Example

The following examples use the border-top-style attribute and the borderTopStyle
property to specify the style of the top border.

This example uses a call to an embedded (global) style sheet to change the style of
the top border from solid to groove when an onmouseover event occurs.

<HEAD>
<STYLE>
TD { border-top-style:solid;
border-width=0.3cm }
.change { border-top-style:groove}
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='change'"
onmouseout="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the style of the top border to groove
when an onmouseover event occurs.

<TD onmouseover="this.style.borderWidth='0.5cm';
this.style.borderTopStyle='groove'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-top-style Attribut... border-width Attribu
Web Workshop | DHTML, HTML & CSS
border-top-width Attribute | borderTopWidth Property
Sets or retrieves the width of the top border of the object.

Syntax

HTML { border-top-width: sWidth }


Scripting object.style.borderTopWidth [ = sWidth ]

Possible Values

sWidth String that specifies one of the following values:


medium Default width.
thin Less than the default width.
thick Greater than the default width.
width Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a relative
units designator (em or ex). For more information about the supported length units, see CSS Length
Units.

The property is read/write with a default value of medium; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

The property is supported on block and replaced objects only.

Example

The following examples use the border-top-width attribute and the


borderTopWidth property to specify the width of the top border.

This example uses a call to an embedded (global) style sheet to change the width of
the top border to 1 centimeter when a mouse click occurs.

<HEAD>
<STYLE>
TD { border-top-width:3mm }
.changeborder1 { border-top-width:1cm }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onclick="this.className='changeborder1'"
ondblclick="this.className=''">
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline script to change the width of the top border to 1 centimeter
when a mouse click occurs.

<TD onclick="this.style.borderTopWidth='1cm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
border-top-width Attribut... bottom Property
Web Workshop | DHTML, HTML & CSS
border-width Attribute | borderWidth Property
Sets or retrieves the width of the left, right, top, and bottom borders of the object.

Syntax

HTML { border-width: sWidth }


Scripting object.style.borderWidth [ = sWidth ]

Possible Values

sWidth String that specifies up to four of the following values:


medium Default width.
thin Width less than the default.
thick Width greater than the default.
width Width consisting of a floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc,
or px) or a relative units designator (em or ex).

The property is read/write with a default value of medium; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Up to four different widths can be specified, in the following order: top, right, bottom,
left. If one width is specified, it is used for all four sides. If two widths are specified,
the first is used for the top and bottom borders, and the second is used for left and
right borders. If three widths are specified, they are used for top, right/left, and
bottom borders, respectively.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

The borderWidth property does not render if the borderStyle property is set to none.

Example

The following examples use the border-width attribute and the borderWidth
property to specify the width of the border.

This example uses a call to an embedded (global) style sheet to change the width of
the border to 1 centimeter when a mouse click occurs.

<HEAD>
<STYLE>
TD { border-width:3mm }
.changeborder1 { border-width:1cm }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onclick="this.className='changeborder1'"
ondblclick="this.className=''">
<IMG src="sphere.jpg"></TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline script to change the width of the border to 1 centimeter when
a mouse click occurs.

<TD onclick="this.style.borderWidth='1cm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

border

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
CLASS Attribute | classNa... CLEAR Attribute |
Web Workshop | DHTML, HTML & CSS
clear Attribute | clear Property
Sets or retrieves whether the object allows floating objects on its left and/or right sides, so
that the next text displays past the floating objects.

Syntax

HTML { clear: sClear }


Scripting object.style.clear [ = sClear ]

Possible Values

sClear String that specifies one of the following values:


none Floating objects are allowed on both sides.
left Object is moved below any floating object on the left side.
right Object is moved below any floating object on the right side.
both Object is moved below any floating object.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The value of this property lists the sides where floating objects are not accepted.

Example

The following examples use the clear attribute and the clear property to specify
placement of text relative to floating objects.

This example uses a call to an embedded (global) style sheet to move the text below
the floating objects when italic text is encountered.

<STYLE>
I { clear:left }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example changes the position of the paragraph relative to the floating object on
its left side.

<HEAD>
<SCRIPT>
function fnClear(){
oClear.style.clear="left";
}
function fnClear2(){
oClear.style.clear="none";
}
</SCRIPT>
</HEAD>

<BODY>
<img src="/workshop/graphics/sphere.jpg" style="float:left">
<SPAN ID="oClear">
<P>This is an example of the clear attribute.<P>
</span>

<P>
<INPUT TYPE=button value="clear = left"
onclick="fnClear()">
<INPUT TYPE=button value="clear = none"
onclick="fnClear2()">
</P>
</BODY>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, EMBED, FIELDSET, FORM, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image,
INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MENU, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP,
TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
firstChild Property font Attribute | font Pro...
Web Workshop | DHTML, HTML & CSS
float Attribute | styleFloat Property
Sets or retrieves on which side of the object the text will flow.

Syntax

HTML { float: sFloat }


Scripting object.style.styleFloat [ = sFloat ]

Possible Values

sFloat String that specifies one of the following values:


none Object displays where it appears in the text.
left Text flows to the right of the object.
right Text flows to the left of the object.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute has a default value of none and is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

With a value of left or right, the object is treated as block-level—that is, the display
property is ignored. For example, floating paragraphs allow the paragraphs to appear
side-by-side on a page.

Objects following a floating object move in relation to the position of the floating
object.

The floating object is moved left or right until it reaches the border, padding, or margin
of another block-level object.

DIV and SPAN objects must have a width set for the float attribute to render. In
Internet Explorer 5, DIV and SPAN objects are assigned a width by default and will
render if a width is not specified.

Example

This example shows how the float attribute affects the flow of the text. The sphere
image floats to the left of the text, and the cone floats to the right.

<img src="sphere.jpg" style="float:left">


<img src="cone.jpg" style="float:right">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.
This example uses inline scripting and the styleFloat property to swap images when
the mouse moves over the button.

<IMG ID=oSphere SRC="sphere.jpeg" STYLE="float:left">


<IMG ID=oCone SRC="cone.jpeg" STYLE="float:right">
:
<BUTTON onmouseover="oSphere.style.styleFloat='right';
oCone.style.styleFloat='left'"
onmouseout="oSphere.style.styleFloat='left';
oCone.style.styleFloat='right'">
Flip-flop images.
</BUTTON>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BUTTON, CENTER, CITE, CODE, currentStyle, custom, DD, DFN, DIR, DIV, DL, DT, EM, EMBED,
FIELDSET, FORM, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password,
INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU,
OBJECT, OL, P, PRE, RT, RUBY, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TEXTAREA, TT, U, UL,
VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
LOWSRC Attribute | lowsrc... margin-bottom At
Web Workshop | DHTML, HTML & CSS
margin Attribute | margin Property
Sets or retrieves the width of the left, right, bottom, and top margins of the object.

Syntax

HTML { margin: sMargin }


Scripting object.style.margin [ = sMargin ]

Possible Values

sMargin String that specifies up to four of the following space-delimited values:


auto Value is equal to the opposite margin.
width Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This is a composite property that specifies up to four width values, in the following
order: top, right, bottom, left. If one width value is specified, it is used for all four
sides. If two width values are specified, the first is used for the top and bottom
borders, and the second is used for left and right borders. If three width values are
specified, they are used for the top, right/left, and bottom borders, respectively.
Negative margins are supported except for top and bottom margins on inline objects.

As of Internet Explorer 4.0, you can specify length values relative to the height of the
element's font (em) or the height of the letter "x" (ex).

In Internet Explorer 3.0, the specified margin value is added to the default value of the
object. In Internet Explorer 4.0 and later, the margin value is absolute. The margin
properties do not work with the TD and TR objects in Internet Explorer 4.0, but they
do work in Internet Explorer 3.0. To set margins in the cell for Internet Explorer 4.0
and later, apply the margin to an object, such as DIV or P, within the TD.

To use this property, inline objects must have an absolute position or layout. Element
layout is set by providing a value for the height property or the width property.

Margins are always transparent.

Example
The following examples use the margin attribute and the margin property to change
the margin of the object.

This example uses the IMG object as a selector to set the margin of images to 1
centimeter.

<STYLE>
IMG { margin:1cm }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the margin of the image to 5 millimeters when
an onmouseover event occurs.

<IMG src="sphere.jpg" onmouseover="this.style.margin='5mm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

CSS Length Units

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
margin Attribute | margin... MARGINHEIGHT At
Web Workshop | DHTML, HTML & CSS
margin-bottom Attribute | marginBottom Property
Sets or retrieves the height of the bottom margin of the object.

Syntax

HTML { margin-bottom: sHeight }


Scripting object.style.marginBottom [ = sHeight ]

Possible Values

sHeight String that specifies one of the following values:


auto Bottom margin is set equal to the top margin.
height Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the height of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

As of Internet Explorer 4.0 and later, you can specify possible length values relative to
the height of the element's font (em) or the height of the letter "x" (ex).

In Internet Explorer 3.0, the specified margin value is added to the default value of the
object. In Internet Explorer 4.0 and later, the margin value is absolute. The margin
properties do not work with the TD and TR objects in Internet Explorer 4.0, but they
do work in Internet Explorer 3.0. To set margins in the cell for Internet Explorer 4.0
and later, apply the margin to an object, such as DIV or P, within the TD.

To use this property, inline objects must have an absolute position or layout. Element
layout is set by providing a value for the height property or the width property.

Negative margins are supported, except for top and bottom margins on inline objects.

Example

The following examples use the margin-bottom attribute and the marginBottom
property to change the margin of the object.

This example uses the IMG object as a selector to set the bottom margin on images to
2 centimeters.

<STYLE>
IMG { margin-bottom:2cm }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the bottom margin of the image to 1
centimeter when an onmouseover event occurs.

<IMG
src="sphere.jpg"onmouseover="this.style.marginBottom='1cm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

CSS Length Units

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
MARGINHEIGHT Attribute | ... margin-right Att
Web Workshop | DHTML, HTML & CSS
margin-left Attribute | marginLeft Property
Sets or retrieves the width of the left margin of the object.

Syntax

HTML { margin-left: sWidth }


Scripting object.style.marginLeft [ = sWidth ]

Possible Values

sWidth String that specifies one of the following values:


auto Left margin is set equal to the right margin.
width Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

As of Internet Explorer 4.0 and later, you can specify possible length values relative to
the height of the element's font (em) or the height of the letter "x" (ex).

In Internet Explorer 3.0, the specified margin value is added to the default value of the
object. In Internet Explorer 4.0 and later, the margin value is absolute. The margin
properties do not work with the TD and TR objects in Internet Explorer 4.0, but they
do work in Internet Explorer 3.0. To set margins in the cell for Internet Explorer 4.0
and later, apply the margin to an object, such as DIV or P, within the TD.

To use this property, inline objects must have an absolute position or layout. Element
layout is set by providing a value for the height property or the width property.

Negative margins are supported, except for top and bottom margins on inline objects.

Example

The following examples use the margin-left attribute and the marginLeft property to
change the margin of the object.

This example uses the IMG object as a selector to set the left margin to 2 centimeters
for all images.

<STYLE>
IMG { margin-left:2cm }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the left margin of the image to 1 centimeter
when an onclick event occurs.

<IMG src="sphere.jpg" onclick="this.style.marginLeft='1cm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

CSS Length Units

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
margin-left Attribute | m... margin-top Attribut
Web Workshop | DHTML, HTML & CSS
margin-right Attribute | marginRight Property
Sets or retrieves the width of the right margin of the object.

Syntax

HTML { margin-right: sWidth }


Scripting object.style.marginRight [ = sWidth ]

Possible Values

sWidth String that specifies one of the following values:


auto Right margin is set equal to the left margin.
width Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

As of Internet Explorer 4.0 and later, you can specify possible length values relative to
the height of the element's font (em) or the height of the letter "x" (ex).

In Internet Explorer 3.0, the specified margin value is added to the default value of the
object. In Internet Explorer 4.0 and later, the margin value is absolute. The margin
properties do not work with the TD and TR objects in Internet Explorer 4.0, but they
do work in Internet Explorer 3.0. To set margins in the cell for Internet Explorer 4.0
and later, apply the margin to an object, such as DIV or P, within the TD.

To use this property, inline objects must have an absolute position or layout. Element
layout is set by providing a value for the height property or the width property.

Negative margins are supported, except for top and bottom margins on inline objects.

Example

The following examples use the margin-right attribute and the marginRight
property to change the margin of the object.

This example uses IMG as a selector and margin1 as a class in an embedded style
sheet to set the right margin of an image when an onclick event or ondblclick event
occurs.
<STYLE>
IMG { margin-right:1cm }
.margin1 { margin-right:2cm }
</STYLE>
</HEAD>
<BODY>
<IMG src="sphere.jpg" onclick="this.className='margin1'"
ondblclick="this.className=''">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the right margin of the image to 1 centimeter
when the onclick event occurs.

<IMG src="sphere.jpeg" onclick="this.style.marginRight='1cm'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

CSS Length Units

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
margin-right Attribute | ... MARGINWIDTH Attr
Web Workshop | DHTML, HTML & CSS
margin-top Attribute | marginTop Property
Sets or retrieves the height of the top margin of the object.

Syntax

HTML { margin-top: sHeight }


Scripting object.style.marginTop [ = sHeight ]

Possible Values

sHeight String that specifies one of the following values:


auto Top margin is set equal to the bottom margin.
height Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the height of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

As of Internet Explorer 4.0 and later, you can specify possible length values relative to
the height of the element's font (em) or the height of the letter "x" (ex).

In Internet Explorer 3.0, the specified margin value is added to the default value of the
object. In Internet Explorer 4.0 and later, the margin value is absolute. The margin
properties do not work with the TD and TR objects in Internet Explorer 4.0, but they
do work in Internet Explorer 3.0. To set margins in the cell for Internet Explorer 4.0
and later, apply the margin to an object, such as DIV or P, within the TD.

To use this property, inline objects must have an absolute position or layout. Element
layout is set by providing a value for the height property or the width property.

Negative margins are supported, except for top and bottom margins on inline objects.

Example

The following examples use the margin-top attribute and the marginTop property to
change the margin of the object.

This example uses HR as a selector and margin1 as a class in an embedded style sheet
to set the top margin of the horizontal rule.

<STYLE>
HR { margin-top:2cm }
.margin1 { margin-top:4cm }
</STYLE>
</HEAD>
<BODY>
<HR onclick="this.className='margin1'"
ondblclick="this.className=''">
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set and reset the margin when the onclick and
ondblclick events occur, respectively.

<HR onclick="this.style.marginTop='2cm'"
ondblclick="this.style.marginTop=''">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, currentStyle, custom, DD, DIR, DIV, DL, DT, EMBED, FIELDSET, FORM, Hn, HR, IFRAME, IMG,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset,
INPUT type=submit, INPUT type=text, ISINDEX, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, SPAN, style, TABLE,
TD, TEXTAREA, TH, UL, XMP

See Also

CSS Length Units

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
owningElement Property padding-bottom Attrib
Web Workshop | DHTML, HTML & CSS
padding Attribute | padding Property
Sets or retrieves the amount of space to insert between the object and its margin or, if
there is a border, between the object and its border.

Syntax

HTML { padding: sPadding }


Scripting object.style.padding [ = sPadding ]

Possible Values

sPadding String that specifies up to four of the following space-delimited values:


length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This is a composite property that specifies up to four padding values, in the following
order: top, right, bottom, left. If one width value is specified, it is used for all four
sides. If two width values are specified, the first is used for the top and bottom
borders, and the second is used for left and right borders. If three width values are
specified, they are used for top, right/left, and bottom borders, respectively. Negative
values are not allowed.

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Example

The following examples use the padding attribute and the padding property to
change the padding of the object.

This example uses TD as a selector and padding1 as a class in an embedded style


sheet to set the padding for the TD object.

<STYLE>
TD { padding:3mm 8mm }
.padding1 { padding:1cm }
</STYLE>
</HEAD>
<BODY>
<TABLE BORDER>
<TR>
<TD onmouseover="this.className='padding1'"
onmouseout="this.className=''" ALIGN=middle>
<IMG src="sphere.jpg">
</TD>
</TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the cell's top and bottom padding to 0.5
centimeters and its left and right padding to 0.2 centimeters when an onmouseover
event occurs.

<TD onmouseover="this.style.padding='0.5cm 0.2cm'"


onmouseout="this.style.padding=''" ALIGN=middle>
<IMG src="sphere.jpeg">
</TD>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD,
DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox,
INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS,
KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, NEXTID, NOBR, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL,
SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
padding Attribute | paddi... padding-left Attribu
Web Workshop | DHTML, HTML & CSS
padding-bottom Attribute | paddingBottom Property
Sets or retrieves the amount of space to insert between the bottom border of the object
and the content.

Syntax

HTML { padding-bottom: sPadding }


Scripting object.style.paddingBottom [ = sPadding ]

Possible Values

sPadding String that specifies one of the following values:


length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Negative values are not allowed.

Example

The following examples use the padding-bottom attribute and the paddingBottom
property to change the padding of the object.

This example uses TD as a selector in an embedded style sheet to set the bottom
padding for all table cells to 1 centimeter.

<STYLE>
TD { padding-bottom:1cm }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the cell's bottom padding to 1 centimeter
when an onmouseover event occurs.
<TD onmouseover="this.style.paddingBottom='1cm'"
onmouseout="this.style.paddingBottom=''">
<IMG src="sphere.jpg">
</TD>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD,
DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox,
INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS,
KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, NEXTID, NOBR, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL,
SPAN, STRIKE, STRONG, SUB, SUP, TD, TEXTAREA, TH, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
padding-bottom Attribute ... padding-right Attr
Web Workshop | DHTML, HTML & CSS
padding-left Attribute | paddingLeft Property
Sets or retrieves the amount of space to insert between the left border of the object and
the content.

Syntax

HTML { padding-left: sPadding }


Scripting object.style.paddingLeft [ = sPadding ]

Possible Values

sPadding String that specifies one of the following values:


length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Negative values are not allowed.

Example

The following examples use the padding-left attribute and the paddingLeft property
to change the padding of the object.

This example uses TD as a selector in an embedded style sheet to set the left padding
for all table cells to 1 centimeter.

<STYLE>
TD { padding-left:1cm }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the cell's left padding to 1 centimeter when an
onmouseover event occurs.
<TD onmouseover="this.style.paddingLeft='1cm'"
onmouseout="this.style.paddingLeft=''">
<IMG src="sphere.jpg">
</TD>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD,
DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox,
INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS,
KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, NEXTID, NOBR, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL,
SPAN, STRIKE, STRONG, SUB, SUP, TD, TEXTAREA, TH, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
padding-left Attribute | ... padding-top Attribut
Web Workshop | DHTML, HTML & CSS
padding-right Attribute | paddingRight Property
Sets or retrieves the amount of space to insert between the right border of the object and
the content.

Syntax

HTML { padding-right: sPadding }


Scripting object.style.paddingRight [ = sPadding ]

Possible Values

sPadding String that specifies one of the following values:


length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Negative values are not allowed.

Example

The following examples use the padding-right attribute and the paddingRight
property to change the padding of the object.

This example uses TD as a selector in an embedded style sheet to set the right
padding for all table cells to 1 centimeter.

<STYLE>
TD { padding-right:1cm }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the cell's right padding to 1 centimeter when
an onmouseover event occurs.
<TD onmouseover="this.style.paddingRight='1cm'"
onmouseout="this.style.paddingRight=''">
<IMG src="sphere.jpg">
</TD>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD,
DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox,
INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS,
KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, NEXTID, NOBR, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL,
SPAN, STRIKE, STRONG, SUB, SUP, TD, TEXTAREA, TH, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
padding-right Attribute |... page-break-after At
Web Workshop | DHTML, HTML & CSS
padding-top Attribute | paddingTop Property
Sets or retrieves the amount of space to insert between the top border of the object and
the content.

Syntax

HTML { padding-top: sPadding }


Scripting object.style.paddingTop [ = sPadding ]

Possible Values

sPadding String that specifies one of the following values:


length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of 0; the cascading style sheets (CSS)
attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

To use this property, inline elements must have an absolute position or layout.
Element layout is set by providing a value for the height property or the width
property.

Negative values are not allowed.

Example

The following examples use the padding-top attribute and the paddingTop property
to change the padding of the object.

This example uses TD as a selector in an embedded style sheet to set the top padding
for all table cells to 1 centimeter.

<STYLE>
TD { padding-top:1cm }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the cell's top padding to 1 centimeter when an
onmouseover event occurs.
<TD onmouseover="this.style.paddingTop='1cm'"
onmouseout="this.style.paddingTop=''">
<IMG src="sphere.jpg">
</TD>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD,
DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox,
INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS,
KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, NEXTID, NOBR, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL,
SPAN, STRIKE, STRONG, SUB, SUP, TD, TEXTAREA, TH, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TABINDEX Attribute | tabI... tagName Property
Web Workshop | DHTML, HTML & CSS
table-layout Attribute | tableLayout Property
Sets or retrieves whether the table layout is fixed.

Syntax

HTML { table-layout : sLayout }


Scripting table.style.tableLayout[ = sLayout ]

Possible Values

sLayout String that specifies one of the following values:


auto Column width is set by the widest unbreakable content in the column cells.
fixed Table and column widths are set either by the sum of the widths on the COL objects or, if these are not
specified, by the width of the first row of cells.

The property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

You can optimize table rendering performance by specifying the tableLayout property.
This property causes Internet Explorer to render the table one row at a time, providing
users with information at a faster pace. The tableLayout property determines column
widths for a table in the following order:

1. By using information in the width property for the COL or COLGROUP element.
2. By using information in the width property for the TD elements in the first row.
3. By dividing the table columns equally, regardless of the size of the content.

If the content of a cell exceeds the fixed width of the column, the content is wrapped
or, if wrapping is not possible, it is clipped. If the tableLayout property is set to
fixed, the overflow property can be used to handle content that exceeds the width of
a TD element. If the row height is specified, wrapped text is clipped when it exceeds
the set height.

Setting the property to fixed significantly improves table rendering speed, particularly
for longer tables.

Setting row height further improves rendering speed, again enabling the browser's
parser to begin rendering the row without having to examine the content of each cell
in the row to determine row height.

Example

This example uses the CSS attribute to set the table layout to fixed.
<TABLE STYLE="table-layout:fixed" WIDTH=600>
<COL WIDTH=100><COL WIDTH=300><COL WIDTH=200>
<TR HEIGHT=20>
<TD>...</TD><TD>...</TD><TD>...</TD>
</TR>
:
</TABLE>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

currentStyle, runtimeStyle, style, TABLE

See Also

enhancing table presentation , width


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
disabled Property documentElement Property
Web Workshop | DHTML, HTML & CSS
display Attribute | display Property
Sets or retrieves whether the object is rendered.

Syntax

HTML { display: sDisplay }


Scripting object.style.display [ = sDisplay ]

Possible Values

sDisplay String that specifies one of the following values:


block Object is rendered as a block element.
none Object is not rendered.
inline Object is rendered as an inline element sized by the dimensions of the content.
list-item Object is rendered as a block element, and a list-item marker is added.
table-header-group Table header is always displayed before all other rows and row groups, and after any top
captions. The header is displayed on each page spanned by a table.
table-footer-group Table footer is always displayed after all other rows and row groups, and before any
bottom captions. The footer is displayed on each page spanned by a table.

The property is read/write with a default value of block for block elements and inline
for inline elements; the cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

In Internet Explorer 4.0, the block, inline, and list-item values are not supported
explicitly, but do render the element.

The block and inline values are supported explicitly as of Internet Explorer 5.

All visible HTML objects are block or inline. For example, a DIV object is a block
element, and a SPAN object is an inline element. Block elements typically start a new
line and can contain other block elements and inline elements. Inline elements do not
typically start a new line and can contain other inline elements or data. Changing the
values for the display property affects the layout of the surrounding content by:

Adding a new line after the element with the value block.
Removing a line from the element with the value inline.
Hiding the data for the element with the value none.
In contrast to the visibility property, display=none reserves no space for the object on
the screen.

The table-header-group and table-footer-group values can be used to specify that


the contents of the THEAD and TFOOT objects are displayed on every page for a table
that spans multiple pages.
Example

This example show the effect of changing the values for the display property between
inline, block, and none.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD,
DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox,
INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS,
KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, NEXTID, NOBR, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL,
SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
linkColor Property list-style-image Attribut...
Web Workshop | DHTML, HTML & CSS
list-style attribute | listStyle Property
Sets or retrieves up to three separate listStyle properties of the object.

Syntax

HTML { list-style: sStyle }


Scripting object.style.listStyle [ = sStyle ]

Possible Values

sStyle String that specifies up to three of the following values, in any order:
type Any of the range of type values available to the listStyleType property.
position Any of the range of position values available to the listStylePosition property.
image Any of the range of image values available to the listStyleImage property.

The property is read/write with a default value set by the browser; the cascading style
sheets (CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The listStyle property is a composite property. When specifying both the type and
image values, the image value takes precedence, unless the image value is set to none
or the image pointed to by the URL cannot display.

When the left margin of a list item is set to 0 using one of the margin properties, the
list item markers do not show. The margin should be set to a minimum of 30 points.

Example

The following examples use the list-style attribute and the listStyle property to set
the list style.

This example uses UL and UL.compact as selectors in an embedded (global) style


sheet to define the styles of two different unordered lists.

Note For the UL.compact to override the image that is set with the UL selector, you
must explicitly set the list-style-image attribute to 'none'.

<STYLE>
UL { list-style: outside url(dot.gif) }
UL.compact { list-style-image:none; list-style: inside
circle }
</STYLE>
</HEAD>
<BODY>
<UL>
<LI>...
<LI>...
</UL>
<UL CLASS=compact>
<LI>...
<LI>...
</UL>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the style of the list. If the default image
cannot be located, a hollow circle is used.

<UL onmouseover="this.style.listStyle='url(dot.gif) circle'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

LI, OL, runtimeStyle, style, UL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
list-style attribute | li... list-style-position Attri.
Web Workshop | DHTML, HTML & CSS
list-style-image Attribute | listStyleImage Property
Sets or retrieves which image to use as a list-item marker for the object.

Syntax

HTML { list-style-image: sLocation }


Scripting object.style.listStyleImage [ = sLocation ]

Possible Values

sLocation String that specifies one of the following values:


none No image is specified.
url(sURL) Location of the image, where sURL is an absolute or relative URL.

The property is read/write with a default value of none; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

When the image is available, it replaces the marker that is set with the listStyleType
marker.

If the left margin of the list item is set to 0 using one of the margin properties, the list-
item markers do not show. The margin should be set to a minimum of 30 points.

Example

The following examples use the list-style-image attribute and the listStyleImage
property to set the image for markers.

This example uses UL as a selector in an embedded (global) style sheet to set the
marker to the dot.gif image.

<STYLE>
UL { list-style-image:url(dot.gif) }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the style of the list-item marker to an
image when an onmouseover event occurs.

<UL onmouseover="this.style.listStyleImage='url(dot.gif)'">
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

currentStyle, LI, OL, runtimeStyle, style, UL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
list-style-image Attribut... list-style-type Attribu
Web Workshop | DHTML, HTML & CSS
list-style-position Attribute | listStylePosition Property
Sets or retrieves how the list-item marker is drawn relative to the content of the object.

Syntax

HTML { list-style-position: sPosition }


Scripting object.style.listStylePosition [ = sPosition ]

Possible Values

sPosition String that specifies one of the following values:


outside Marker is placed outside the text, and any wrapping text is not aligned under the marker.
inside Marker is placed inside the text, and any wrapping text is aligned under the marker.

The property is read/write with a default value of outside; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This property applies only to objects with a display value of list-item.

If the left margin of a list item is set to 0 using one of the margin properties, the list-
item markers do not show. The margin should be set to a minimum of 30 points.

Example

The following examples use the list-style-position attribute and the


listStylePosition property to set the position for markers.

This example uses UL and UL.compact as selectors in an embedded (global) style


sheet to set the position of the list-item markers.

<STYLE>
UL { list-style-position:inside }
UL.compact { list-style-position:outside }
</STYLE>
</HEAD>
<BODY>
<UL>
<LI>...
<LI>...
</UL>
<UL CLASS=compact>
<LI>...
<LI>...
</UL>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the marker position when an
onmouseover event occurs.

<SPAN STYLE="width:3cm"
onmouseover="this.style.listStylePosition='inside'"
onmouseout="this.style.listStylePosition='outside'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

currentStyle, LI, OL, runtimeStyle, style, UL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
list-style-position Attri... LOOP Attribute | loop
Web Workshop | DHTML, HTML & CSS
list-style-type Attribute | listStyleType Property
Sets or retrieves the predefined type of the line-item marker for the object.

Syntax

HTML { list-style-type: sType }


Scripting object.style.listStyleType [ = sType ]

Possible Values

sType String that specifies one of the following values:


disc Solid circles.
circle Outlined circles.
square Solid squares.
decimal 1, 2, 3, 4, and so on.
lower-roman i, ii, iii, iv, and so on.
upper-roman I, II, III, IV, and so on.
lower-alpha a, b, c, d, and so on.
upper-alpha A, B, C, D, and so on.
none No marker is shown.

The property is read/write with a default value of disc; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The listStyleType property determines the appearance of the list-item marker if the
value of the list-style-image attribute is set to none, or if the image pointed to by the
URL cannot be displayed.

If the left margin of a line item is set to 0 using one of the margin properties, the list-
item markers do not show. The margin should be set to a minimum of 30 points.

Example

The following examples use the list-style-type attribute and the listStyleType
property to set the markers.

This example uses UL as a selector in an embedded (global) style sheet to change the
marker type to circle.

<STYLE>
UL { list-style-type:circle }
</STYLE>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the marker type on when an onmouseover
event occurs.

<UL onmouseover="this.style.listStyleType='circle'">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

currentStyle, LI, OL, runtimeStyle, style, UL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
bottom Property BOTTOMMARGIN Attribute | ..
Web Workshop | DHTML, HTML & CSS
bottom Attribute | bottom Property
Sets or retrieves the bottom position of the object in relation to the bottom of the next
positioned object in the document hierarchy.

Syntax

HTML { bottom: sBottom }


Scripting object.style.bottom [ = sBottom ]

Possible Values

sBottom String that specifies one of the following values:


auto Default position, according to the regular HTML layout of the page.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the height of the parent object.

The property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The bottom attribute should be used only when the position attribute is set;
otherwise, the value of the bottom attribute is ignored.

Because the value of the bottom property is a string, the property cannot be used in
script to calculate the position of the object in the document; instead, the pixelBottom
property or the posBottom property should be used.

For more information about how to access the dimension and location of objects on the
page through the DHTML object model, see measuring element dimension and location
.
I
Example

This example uses the bottom attribute to set a DIV object 50 pixels from the bottom
of the client area.

<DIV STYLE = "position:absolute; bottom:50px">


. . .
</DIV>

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BUTTON, CENTER, CITE, CODE, currentStyle, custom, DD, DFN, DIR, DIV, DL, FIELDSET, FORM, Hn,
HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio,
INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PRE,
runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TEXTAREA, TT, U, UL, VAR, XMP

See Also

pixelTop, posTop

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
clientY Property clipBottom Property DHTML P
Web Workshop | DHTML, HTML & CSS
clip Attribute | clip Property
Sets or retrieves which part of a positioned object is visible.

Syntax

HTML { clip: sClip }


Scripting object.style.clip [ = sClip ]

Possible Values

sClip String that specifies one of the following values:


auto Clip to expose entire object.
rect(top right Top, right, bottom, and left specify length values, any of which may be replaced by auto,
bottom left) leaving that side not clipped.

The property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This property defines the shape and size of the positioned object that is visible. The
position must be set to absolute. Any part of the object that is outside the clipping
region is transparent. Any coordinate can be replaced by the value auto, which
exposes the respective side (meaning the side is not clipped).

The order of the values clip:rect(0 0 50 50) renders the object invisible as it sets
the top and right positions of the clipping region to 0. To achieve a 50-by-50 view port,
use clip:rect(0 50 50 0).

The clip attribute and the clip property are available on the Macintosh platform, as of
Internet Explorer 5.

Example

The following examples use clip attribute and the clip property to modify the
appearance of an image.

This example uses a call to an embedded (global) style sheet to clip the image.

<DIV Style="position:absolute;top:0;left:200;
clip:rect(0.6cm 3cm 2cm 0.5cm)">
<IMG SRC="sphere.jpg">
</DIV>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to clip the image.

<IMG ID="sphere" SRC="sphere.jpeg"


STYLE="position:absolute;top:0cm;left:0cm;">
<BUTTON
onclick="sphere.style.clip='rect(0.2cm 0.6cm 1cm 0.1cm)'">
Clip Image</BUTTON>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BUTTON, CENTER, CITE, CODE, custom, DD, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET,
FORM, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT
type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OBJECT, OL,
P, PRE, RUBY, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TD, TEXTAREA, TH, TR, TT, U, UL, VAR,
XMP

See Also

clipBottom, clipLeft, clipRight, clipTop

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
height Property HEIGHT Attribute | height...
Web Workshop | DHTML, HTML & CSS
height Attribute | height Property
Sets or retrieves the height of the object.

Syntax

HTML { height: sHeight }


Scripting object.style.height [ = sHeight ]

Possible Values

sHeight String that specifies one of the following values:


auto Default height.
height Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the height of the parent object.

The property is read/write with a default value of auto; the CSS attribute is not
inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

If the height property of an IMG is specified, but width property is not specified, the
resulting width of the IMG is sized proportionally according to the specified height
property and the actual width (in pixels) of the image in the source file.

Consider the following:

Dimensions of image in source file (pixels): 100 X 50 (W X H)


Specified image height: 2in
Specified image width: not specified
Resulting image height: 2in
Resulting image width: 4in ((100 / 50) * 2 inches)

If you specify the height property of an IMG, and both the height and width of the
image in the source file are identical, the width of the image will match the height.

If you specify the height property and width property of an IMG, the resulting image
dimensions will match those specified.

The height of a block object encompasses border-top, border-bottom, padding-


top, padding-bottom, margin-top, margin-bottom, and height. The sum of the
values of each of the attributes equals the height of the parent object's content.

Percentage values refer to the parent object's height. Negative values are not allowed.

To perform operations on the numeric value of this property, use pixelHeight or


posHeight.
For more information about how to access the dimension and location of objects on the
page through the document object model, see measuring element dimension and
location .
I
Example

The following examples use the height attribute and the height property to change
the height of the object.

This example uses an inline style sheet to set the height of an image to 4 centimeters.

<IMG SRC="sphere.jpg" STYLE="height:4cm">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the height of an image when an onclick
event occurs.

<BUTTON onclick="height1.style.height='1cm'">Shrink
sphere</BUTTON>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

APPLET, BUTTON, currentStyle, custom, DIV, EMBED, FIELDSET, HR, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file,
INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, MARQUEE,
OBJECT, runtimeStyle, SPAN, style, TABLE, TEXTAREA, TR

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
layout-grid-type Attribut... left Property DHTM
Web Workshop | DHTML, HTML & CSS
left Attribute | left Property
Sets or retrieves the position of the object relative to the left edge of the next positioned
object in the document hierarchy.

Syntax

HTML { left: sPosition }


Scripting object.style.left [ = sPosition ]

Possible Values

sPosition String that specifies one of the following values:


auto Default position, according to the regular HTML layout of the page.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

This property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

You should use the left attribute only when the position attribute is set; otherwise, the
value of the left attribute is ignored.

Because the value of the left property is a string, you cannot use the property in script
to calculate the position of the object in the document; instead, you should use the
pixelLeft property or the posLeft property.

For more information about how to access the dimension and location of objects on the
page through the DHTML object model, see measuring element dimension and location
.
I
Example

The following examples use the left attribute and the left property to change the
position of the object.

This example uses an inline style sheet to set the position of an image 100 pixels to
the right of the parent object's left edge.

<DIV STYLE="position:absolute;left:100px">
<IMG SRC="cone.jpg"></DIV>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to change the position of two images when an
onclick event occurs.

<BUTTON onclick="cone.style.left='100px';
sphere.style.left='200px'">
. . .</BUTTON>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BUTTON, CENTER, CITE, CODE, currentStyle, custom, DD, DFN, DIR, DIV, DL, DT, EM, EMBED,
FIELDSET, FORM, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password,
INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU,
OBJECT, OL, P, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TEXTAREA, TT, U, UL, VAR, XMP

See Also

pixelLeft, posLeft

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
outerText Property overflow-x Attribute | ov...
Web Workshop | DHTML, HTML & CSS
overflow Attribute | overflow Property
Sets or retrieves how to manage the content of the object when the content exceeds the
height and/or width of the object.

Syntax

HTML { overflow: sOverflow }


Scripting object.style.overflow [ = sOverflow ]

Possible Values

sOverflow String that specifies one of the following values:


visible Content is not clipped, and scroll bars are not added.
scroll Content is clipped, and scroll bars are added even if the content does not exceed the dimensions of
the object.
hidden Content that exceeds the dimensions of the object is not shown.
auto Content is clipped, and scrolling is added only when necessary.

The property is read/write with a default value of visible; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The default value for the BODY element is auto.

For the TEXTAREA object, only the hidden value is valid. Setting the overflow
property to hidden on a TEXTAREA object hides its scroll bars.

The default value for the TABLE element is hidden.

As of Internet Explorer 5, the TD element supports the overflow property, with a


default value of hidden, if the tableLayout property for the parent TABLE is set to
fixed. In a fixed table layout, content that exceeds the dimensions of the cell is
clipped if the overflow property is set to either hidden, scroll, or auto. Otherwise,
setting the value of the overflow property to visible causes the extra text to
overflow into the right neighboring cell (or left if the direction property is set to rtl),
continuing until the end of the row.

Setting the overflow property to visible causes the content to clip to the size of the
window or frame that contains the object.

This property is available on the Macintosh® platform as of Internet Explorer 5.

Example
The following examples use the overflow attribute and the overflow property to
manage content of the object.

This example uses an inline style to automatically adjust itself to overflowing content
when the page is loaded.

<DIV ID=oDiv STYLE="width: 200px; height: 200px; overflow:


auto;">
:
</DIV>

This example allows the user to dynamically change the overflow property of a DIV
object by choosing one of the possible overflow values from a SELECT object.

<SCRIPT>
function SetOverflow(o, sValue)
{
o.style.overflow = sValue;
}
</SCRIPT>

<DIV ID="div1"
STYLE="font-size:18pt;background-
color:yellow;height:50px;width:75px">
The quick brown fox jumped over the lazy dog.
</DIV>

<SELECT onchange="SetOverflow(div1,
this.options[this.selectedIndex].text)">
<OPTION SELECTED>visible
<OPTION>scroll
<OPTION>hidden
<OPTION>auto
</SELECT>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, CENTER, CITE, CODE, currentStyle, custom, DD, DEL, DFN, DIR, DIV, DL, DT,
EM, EMBED, FIELDSET, FONT, FORM, Hn, I, INS, KBD, LABEL, LEGEND, LI, LISTING, MENU, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, runtimeStyle, S,
SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TD, TEXTAREA, TT, U, UL, VAR, XMP

See Also

overflowX, overflowY, position


Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
overflow Attribute | over... overflow-y Attribute
Web Workshop | DHTML, HTML & CSS
overflow-x Attribute | overflowX Property
Sets or retrieves how to manage the content of the object when the content exceeds the
width of the object.

Syntax

HTML { overflow-x:sOverflow }
Scripting object.style.overflowX [ =sOverflow ]

Possible Values

sOverflow String that specifies one of the following values:


visible Content is not clipped, and scroll bars are not added. Elements are clipped to the size of the
containing window or frame.
scroll Content is clipped, and scroll bars are added even if the content does not exceed the dimensions of
the object.
hidden Content that exceeds the dimensions of the object is not shown.
auto Content is clipped, and scrolling is added only when necessary.

The property is read/write with a default value of visible; the proposed cascading
style sheets (CSS) extension attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

For the TEXTAREA object, only the hidden value is valid. Setting the property to
hidden on a TEXTAREA object hides its scroll bars.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, CENTER, CITE, CODE, currentStyle, custom, DD, DEL, DFN, DIR, DIV, DL, DT,
EM, EMBED, FIELDSET, FONT, FORM, Hn, I, IFRAME, INS, KBD, LABEL, LEGEND, LI, LISTING, MENU, OL, P, PLAINTEXT, PRE, Q, RT, RUBY,
runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TEXTAREA, TT, U, UL, VAR, XMP

See Also

overflow, overflowY, position

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
overflow-x Attribute | ov... owningElement Prop
Web Workshop | DHTML, HTML & CSS
overflow-y Attribute | overflowY Property
Sets or retrieves how to manage the content of the object when the content exceeds the
height of the object.

Syntax

HTML { overflow-y:sOverflow }
Scripting object.style.overflowY [ =sOverflow ]

Possible Values

sOverflow String that specifies one of the following values:


visible Content is not clipped, and scroll bars are not added. Elements are clipped to the size of the
containing window or frame.
scroll Content is clipped, and scroll bars are added even if the content does not exceed the dimensions of
the object.
hidden Content that exceeds the dimensions of the object is not shown.
auto Content is clipped, and scrolling is added only when necessary.

The property is read/write with a default value of visible; the proposed cascading
style sheets (CSS) extension attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

For the TEXTAREA object, only the hidden value is valid. Setting the property to
hidden on a TEXTAREA object hides its scroll bars.

Applies To

A, ACRONYM, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BODY, CENTER, CITE, CODE, currentStyle, custom, DD, DEL, DFN, DIR, DIV, DL, DT,
EM, EMBED, FIELDSET, FONT, FORM, Hn, I, IFRAME, INS, KBD, LABEL, LEGEND, LI, LISTING, MENU, OL, P, PLAINTEXT, PRE, Q, RT, RUBY,
runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TEXTAREA, TT, U, UL, VAR, XMP

See Also

overflow, overflowX, position

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
posHeight Property posLeft Property DHTML P
Web Workshop | DHTML, HTML & CSS
position Attribute | position Property
Retrieves the type of positioning used for the object.

Syntax

HTML { position: sPosition }


Scripting [ sPosition = ] object.style.position

Possible Values

sPosition String that specifies one of the following values:


static Object has no special positioning; it follows the layout rules of HTML.
absolute Object is positioned relative to parent element's position—or to the BODY object if its parent element
is not positioned—using the top and left properties.
relative Object is positioned according to the normal flow, and then offset by the top and left properties.

The property is read-only with a default value of static; the cascading style sheets
(CSS) attribute is not inherited.

Remarks

Setting the property to absolute pulls the object out of the "flow" of the document
and positions it regardless of the layout of surrounding objects. If other objects already
occupy the given position, they do not affect the positioned object, nor does the
positioned object affect them. Instead, all objects are drawn at the same place,
causing the objects to overlap. This overlap is controlled by using the z-index attribute
or property. Absolutely positioned objects do not have margins, but they do have
borders and padding.

Setting the property to relative places the object in the natural HTML flow of the
document, but offsets the position of the object based on the preceding content. The
following syntax shows how to create superscript text by placing the text in a SPAN
that is positioned relative to the remaining text in the paragraph.

<P>The superscript in this name


<SPAN STYLE="position:relative;
top:-3px">xyz </SPAN> is "xyz".</P>

Text and objects that follow a relatively positioned object occupy their own space and
do not overlap the natural space for the positioned object. In contrast, text and objects
that follow an absolutely positioned object occupy what would have been the natural
space for the positioned object before it was pulled out of the flow.

The size of the content determines the size of objects with layout. For example, setting
the height and position properties on a DIV object gives it layout. The content of the
DIV determines the size. In this case, the content determines the size of the width.
For an overview about how to use dynamic positioning, see positioning .
I
See the Applies To section for elements that can be relatively and absolutely
positioned.

Example

This examples uses the position property's absolute, static, and relative values
to change the position of the text.

Applies To

A, ADDRESS, APPLET, B, BDO, BIG, BLOCKQUOTE, BUTTON, CENTER, CITE, CODE, custom, DD, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET,
FORM, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT
type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OBJECT, OL,
P, PRE, RUBY, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TD, TEXTAREA, TH, TR, TT, U, UL, VAR,
XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
right Property RIGHTMARGIN Attribute | r... D
Web Workshop | DHTML, HTML & CSS
right Attribute | right Property
Sets or retrieves the position of the object relative to the right edge of the next positioned
object in the document hierarchy.

Syntax

HTML { right: sPosition }


Scripting object.style.right [ = sPosition ]

Possible Values

sPosition String that specifies one of the following values:


auto Default position according to the regular HTML layout of the page.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see
CSS Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Only use the right attribute when the position attribute is set; otherwise, the value of
the right attribute is ignored.

You cannot use the right property in script to calculate the position of the object in the
document, because the value of the right property is a string. Instead, use the
pixelRight property or the posRight property.

For more information about how to access the dimension and location of objects on the
page through the document object model, see measuring element dimension and
location .
I
Example

This example uses the right attribute to set a DIV object 50 pixels from the right of
the client area.

<DIV STYLE = "position:absolute; right:50px">


. . .
</DIV>

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BUTTON, CENTER, CITE, CODE, currentStyle, DD, DFN, DIR, DIV, DL, FIELDSET, FORM, Hn, HR, I,
IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT
type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PRE,
runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TEXTAREA, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
toElement Property top Property DHTML Prop
Web Workshop | DHTML, HTML & CSS
top Attribute | top Property
Sets or retrieves the position of the object relative to the top of the next positioned object
in the document hierarchy.

Syntax

HTML { top: sTop }


Scripting object.style.top [ = sTop ]

Possible Values

sTop String that specifies one of the following values:


auto Default position according to the regular HTML layout of the page.
length Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a relative
units designator (em or ex). For more information about the supported length units, see CSS Length
Units.
percentage Integer, followed by a %. This value is a percentage of the height of the parent object.

The property is read/write with a default value of auto; the CSS attribute is not
inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The top attribute should be used only when the position attribute is set; otherwise, the
value of the top attribute is ignored.

Because the value of the top property is a string, you cannot use the property in script
to calculate the position of the object in the document; instead, use the pixelTop or the
posTop property.

For more information about how to access the dimension and location of objects on the
page through the document object model, see measuring element dimension and
location .
I
Example

The following examples use the top attribute and the top property to change the
position of the object.

This example uses an inline style to set the position of a DIV object.

<DIV STYLE="position:absolute;top:100px">
. . . </DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.
This example uses inline script to change the position of the image set by an inline
style. The change occurs during onmouseover and onmouseout events.

<IMG SRC="cone.jpg" STYLE="position:absolute;


top:80px;" onmouseover="this.style.top='100px''"
onmouseout="this.style.top='80px'" >

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BUTTON, CENTER, CITE, CODE, currentStyle, custom, DD, DFN, DIR, DIV, DL, DT, EM, EMBED,
FIELDSET, FORM, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password,
INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU,
OBJECT, OL, P, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TEXTAREA, TT, U, UL, VAR, XMP

See Also

pixelTop, posTop

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
vertical-align Attribute ... visited Pseudo-class
Web Workshop | DHTML, HTML & CSS
visibility Attribute | visibility Property
Sets or retrieves whether the content of the object is displayed.

Syntax

HTML { visibility: sVisibility }


Scripting object.style.visibility [ = sVisibility ]

Possible Values

sVisibility String that specifies one of the following values:


inherit Object inherits the visibility of the next parent object.
visible Object is visible.
hidden Object is hidden.

The property is read/write with a default value of inherit; the cascading style sheets
(CSS) attribute is not inherited unless the value is set to inherit.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Unlike display:none, objects that are not visible still reserve the same physical space in
the content layout as they would if they were visible. You can change the visibility
through scripting to show and hide overlapping content based on user interaction. For
a child object to be visible, the parent object also must be visible. For document style
scripting information, see dynamic styles .
I
Example

The following examples use the visibility attribute and the visibility property to
determine whether the object is visible.

This example uses two calls to an embedded (global) style sheet to hide and then
show the image when the user moves the mouse over and off the text.

<STYLE>
.vis1 { visibility:visible }
.vis2 { visibility:hidden }
</STYLE>
</HEAD>
<BODY>
<IMG ID="oSphere" SRC="sphere.jpg">
<P onmouseover="oSphere.className='vis2'"
onmouseout="oSphere.className='vis1'">
Move the mouse over this text to make the sphere
disappear.</P>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses a call to a function to hide the image.

<SCRIPT>
function disappear()
{
oSphere.style.visibility="hidden";
}
function reappear()
{
oSphere.style.visibility="visible";
}
</SCRIPT>
</HEAD>
<BODY>
<IMG SRC="sphere.jpeg" ID="oSphere">
Move the mouse over <SPAN ID="oTxt" onmouseover="disappear()"
onmouseout="reappear()"> this text</SPAN>
to see the sphere disappear.

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN,
DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FORM, Hn, HR, HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file,
INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, ISINDEX, KBD, LABEL,
LEGEND, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PRE, runtimeStyle, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP,
TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
WIDTH Attribute | width P... word-break Attribu
Web Workshop | DHTML, HTML & CSS
width Attribute | width Property
Sets or retrieves the width of the object.

Syntax

HTML { width: sWidth }


Scripting object.style.width [ = sWidth ]

Possible Values

sWidth String that specifies one of the following values:


auto Default width of the object.
width Floating-point number, followed by an absolute units designator (cm, mm, in, pt, pc, or px) or a
relative units designator (em or ex). For more information about the supported length units, see CSS
Length Units.
percentage Integer, followed by a %. The value is a percentage of the width of the parent object.

The property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

If you specify the width property of an IMG, but not the height property, the resulting
height of the IMG is sized proportionally to the specified width property and the
actual height, in pixels, of the source image file. Consider the following example:

Dimensions of image in source file (pixels): 100 X 50 (W X H)


Specified image width: 2in
Specified image height: not specified
Resulting image width: 2in
Resulting image height: 1in ((50/100) * 2 inches)

If you specify the width property of an IMG, and the height and width of the image in
the source file are identical, the height of the image matches the width.

If you specify the height property and the width property of an IMG, the resulting
image dimensions match the height and width specified.

The width of a block object encompasses borderLeft, borderRight, paddingLeft,


paddingRight, marginLeft, marginRight, and width—the sum of which equals the width
of the parent's content.

Percentage values refer to the parent object's width. Negative values are not allowed.

To perform operations on the numeric value of this property, use pixelWidth or


posWidth.
For more information about how to access the dimension and location of elements on
the page through the document object model, see measuring element dimension and
location .
I
Example

The following examples use the width attribute and the width property to change the
width of the object.

This example uses an inline style sheet to set the width of an image.

<DIV STYLE="position:absolute;top:10px;left:10px;width=1in">
. . . </DIV>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the width of an image when an onclick event
occurs.

<IMG SRC="sphere.jpg" onclick="this.style.width='1cm'"


ondblclick="this.style.width=''">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE, CODE, COL,
COLGROUP, COMMENT, currentStyle, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD,
Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT
type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, KBD, LABEL, LEGEND, LI, LINK, MAP, MARQUEE, MENU, META, NEXTID,
NOBR, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, runtimeStyle, S, SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, style,
SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
y Property DHTML Properties
Web Workshop | DHTML, HTML & CSS
z-index Attribute | zIndex Property
Sets or retrieves the stacking order of positioned objects.

Syntax

HTML { z-index: vOrder }


Scripting object.style.zIndex [ = vOrder ]

Possible Values

vOrder Variant that specifies one of the following values:


auto String that specifies the stacking order of the positioned objects
based on the order in which the objects appear in the HTML
source.
order Integer that specifies the position of the object in the stacking
order.

The property is read/write with a default value of auto;


the cascading style sheets (CSS) attribute is not inherited.

Expressions can be used in place of the preceding


value(s), as of Microsoft® Internet Explorer 5. For more
information, see dynamic properties .
I
Remarks

Positive z-index values are positioned above a negative


(or lesser value) z-index. Two objects with the same z-
index are stacked according to source order.

Example

The following examples use the z-index attribute and the


zIndex property to change the stacking order of objects.
This example uses an inline style sheet to set the stacking
order.

<IMG SRC="cone.jpg"
STYLE="position:absolute;
top:100; left:100; z-index:4">
<DIV STYLE="position:absolute; top:100;
left:100;
color:red; background-color:beige;
font-weight:bold;
z-index:1">
. . . </DIV>

This feature requires Internet Explorer 4.0 or later. Click


the icon below to install the latest version. Then reload
this page to view the sample.

This example uses inline scripting to set the stacking


order.

<IMG ID="cone" SRC="cone.jpeg"

STYLE="position:absolute;top:10px;left:10px
;"
onclick="cone.style.zIndex=1;
sphere.style.zIndex=2">
<IMG ID="sphere" SRC="sphere.jpg"

STYLE="position:absolute;top:1px;left:1px;"
onclick="cone.style.zIndex=2;
sphere.style.zIndex=1">
This feature requires Internet Explorer 4.0 or later. Click
the icon below to install the latest version. Then reload
this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE,
COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV, DL, DT, EM, FIELDSET, FORM, I,
INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text,
ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P, PLAINTEXT, PRE,
runtimeStyle, S, SAMP, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
padding-top Attribute | p... page-break-before
Web Workshop | DHTML, HTML & CSS
page-break-after Attribute | pageBreakAfter Property
Sets or retrieves whether a page break occurs after the object.

Syntax

HTML { page-break-after: sBreak }


Scripting object.style.pageBreakAfter [ = sBreak ]

Possible Values

sBreak String that specifies one of the following values:


always Always insert a page break after the object.
auto Neither force nor forbid a page break after the object.
"" Empty string does not insert a page break.

The property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This property applies when printing the document.

If there are conflicts between this property and the pageBreakBefore value on the
object previously displayed in the browser, the value that results in the largest number
of page breaks is used.

Page breaks are not permitted inside positioned objects.

Example

The following examples use the page-break-after attribute and the pageBreakAfter
property to start printing on a new page.

This example uses the P element as a selector in an embedded style sheet to break the
page at the end of all paragraphs.

<STYLE>
P { page-break-after: always }
</STYLE>
</HEAD>
<BODY>
<P>
:
</P>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses a call to a function to turn off the page break after the object that
has an id value of idParagraph.

<SCRIPT>
function offBreak()
{
idParagraph.style.pageBreakAfter="";
}
</SCRIPT>
</HEAD>
<BODY>
<BUTTON onClick="offBreak()">Turn off break</BUTTON>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CENTER, currentStyle, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, ISINDEX, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, runtimeStyle, style, TABLE, TD, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
page-break-after Attribut... palette Property D
Web Workshop | DHTML, HTML & CSS
page-break-before Attribute | pageBreakBefore Property
Sets or retrieves whether a page break occurs before the object.

Syntax

HTML { page-break-before: sBreak }


Scripting object.style.pageBreakBefore [ = sBreak ]

Possible Values

sBreak String that specifies one of the following values:


always Always insert a page break before the object.
auto Neither force nor forbid a page break before the object.
"" Empty string does not insert a page break.

The property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

This property applies when printing the document.

If there are conflicts between this property and the pageBreakAfter value object
previously displayed in the browser, the value that results in the largest number of
page breaks is used.

Page breaks are not permitted inside positioned objects.

Example

The following examples use the page-break-before attribute and the


pageBreakBefore property to start printing on a new page.

This example uses the H3 element as a selector in an embedded style sheet to break
the page before all H3 headings.

<STYLE>
H3 { page-break-before: always }
</STYLE>
</HEAD>
<BODY>
<H3>Start New Section on New Page</H3>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.
This example uses a call to a function to turn off the page break before the object that
has an id value of idParagraph. When the page is printed, a page break occurs before
the first paragraph unless the user clicks the Turn Off Break button.

<SCRIPT>
function offBreak()
{
idParagraph.style.pageBreakBefore="";
}
</SCRIPT>
</HEAD>
<BODY>
<BUTTON onClick="offBreak()">Turn off break</BUTTON>
<P ID="Paragraph" STYLE="page-break-before:always">
:
</P>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

BLOCKQUOTE, BODY, BUTTON, CENTER, currentStyle, DD, DIR, DIV, DL, DT, FIELDSET, FORM, Hn, ISINDEX, LI, LISTING, MARQUEE, MENU, OL, P,
PLAINTEXT, PRE, runtimeStyle, style, TABLE, TD, TR, UL, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
fileUpdatedDate Property firstChild Property D
Web Workshop | DHTML, HTML & CSS
filter Attribute | filter Property
Sets or retrieves the filter or collection of filters applied to the object.

Syntax

HTML { filter: sFilter }


Scripting object.style.filter [ = sFilter ]

Possible Values

sFilter String that specifies one of the following values:


filtertype1 (parameter1, parameter2,...) Any of the filters listed in the Visual Filters and Transitions Reference.
filtertype2 (parameter1, parameter2,...) Any of the filters listed in the Visual Filters and Transitions Reference.

The property is read/write with no default value; the proposed cascading style sheets
(CSS) extension attribute is not inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

When using a SPAN or DIV object, be sure to specify at least one of the three required
CSS attributes: height, width, or position (absolute or relative).

The shadow filter can be applied to the IMG object by setting the filter on the image's
parent container.

For more information about filters, see creating multimedia effects with visual filters
and transitions . The filter mechanism is extensible and allows you to develop and add
I
additional filters later.

Not available on the Macintosh platform.

Example

The following examples use the filter attribute and the filter property to apply filters.

This example uses an inline style sheet to set the filter on an image.

<IMG STYLE="filter:blur(strength=50) flipv()"


SRC="cone.jpg">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the filter on an image.


Applies To

BODY, BUTTON, custom, DIV, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT type=password, INPUT
type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, MARQUEE, runtimeStyle, SPAN, style, TABLE, TD, TEXTAREA, TH

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ACTION Attribute | action... activeElement Prop
Web Workshop | DHTML, HTML & CSS
active Pseudo-class
Sets the style of anchor when the link is engaged or active.

Syntax

HTML [A]:active { attribute1:parameter1 [; attribute2:parameter2 [; . . .]] }


Scripting N/A

Possible Values

attribute Any attribute applicable to text.


parameter Any of the range of values available to the corresponding attribute.

The default value is browser-specific.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Active means that the user currently is navigating the link. The active pseudo-class is
often used to set specific styles for the other states of a link: link, visited, and hover.
Using pseudo-classes on objects other than the A object has no effect.

Example

This example uses the active pseudo-class to set the attributes of the active link.

A:active { font-weight:bold; color:purple }

Applies To

HTML A
Scripting N/A

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
ctrlKey Property DATA Attribute | data Pro...
Web Workshop | DHTML, HTML & CSS
cursor Attribute | cursor Property
Sets or retrieves the type of cursor to display as the mouse pointer moves over the object.

Syntax

HTML { cursor: sCursor }


Scripting object.style.cursor [ = sCursor ]

Possible Values

sCursor String that specifies one of the following values:


auto Browser determines which cursor to display based on the current context.
crosshair Simple cross hair.
default Platform-dependent default cursor (usually an arrow).
hand Hand.
move Crossed arrows indicating something is to be moved.
*-resize Arrow indicating edge is to be moved (*may be n, ne, nw, s, se, sw, e, or w—each representing a
compass direction).
text Editable text (usually an I-bar).
wait Hourglass or watch indicating that the program is busy and the user should wait.
help Arrow with question mark indicating Help is available.

The property is read/write with a default value of auto; the cascading style sheets
(CSS) attribute is inherited.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Example

The following examples use the cursor attribute and the cursor property to change
the cursor as it passes over an object.

This example uses a call to an embedded (global) style sheet to set the cursor to hand
as the cursor passes over all paragraphs.

<STYLE>
P { cursor:hand }
</STYLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

This example uses inline scripting to set the cursor to hand as the cursor passes over
the paragraph.

<P onmouseover="this.style.cursor='hand'">
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BODY, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, currentStyle, custom, DD, DFN, DIR, DIV,
DL, DT, EM, EMBED, FIELDSET, FORM, Hn, HR, HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT
type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, KBD, LABEL, LEGEND, LI,
LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, runtimeStyle, S, SAMP, SMALL, SPAN, STRIKE, STRONG, style, SUB, SUP, TABLE,
TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
hostname Property href Property DHTML Prop
Web Workshop | DHTML, HTML & CSS
hover Pseudo-class
Sets the style of the anchor when the user hovers the mouse over the links.

Syntax

HTML [A]:hover { attribute1:parameter1 [; attribute2:parameter2 [; . . .]] }


Scripting N/A

Possible Values

attribute Any attribute applicable to text.


parameter Any of the range of values available to the corresponding attribute.

The default value is browser-specific.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

Hover means that the user has the mouse positioned over the link and has hesitated.
If the user simply passes the mouse over the link, the style does change. The hover
pseudo-class is often used with specific styles for the other states of a link: active,
link, and visited.

Using pseudo-classes on objects other than the A object has no effect.

The syntax in the following example uses a colon (:) to specify a pseudo-class.

Example

This example sets the style of an anchor. When the user hovers the mouse over a
hyperlink to which the following style sheet has been applied, the text displays in red,
converts to uppercase, and is spaced 1 centimeter apart.

<STYLE>
A:hover { color:red; text-transform:uppercase; letter-
spacing:1cm }
</STYLE>

Applies To

See Also

active, link, visited

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
@font-face Rule @media Rule DHTML Propert
Web Workshop | DHTML, HTML & CSS
@import Rule
Imports an external style sheet.

Syntax

HTML @import url(sUrl);


Scripting N/A

Possible Values

sUrl String that specifies the URL that references a cascading style sheet.

The rule has no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The semicolon in the syntax is required; if omitted, the style sheet is not imported
properly and an error message is generated.

The @import rule, like the LINK element, links an external style sheet to a document.
This helps the Web author establish a consistent "look" across multiple HTML pages.
Whereas the LINK element specifies the name of the style sheet to import using its
HREF attribute, the @import rule specifies the style sheet definition inside a LINK or
a STYLE tag. In the scripting model, this means the owningElement property of the
style sheet defined through the @import rule is either a STYLE or a LINK object.

The @import rule should occur at the start of a style sheet, before any declarations.
Although Internet Explorer 4.0 allows @import statements to appear anywhere within
the style sheet definition, the rules contained within the @import style sheet are
applied to the document before any other rules defined for the containing style sheet.
This rule order affects expected rendering.

Rules in the style sheet override rules in the imported style sheet.

Example

This example uses the @import rule to import a style sheet located at
http://anotherStyleSheet.css.

<STYLE type="css/text">
@import url(http://anotherStyleSheet.css);
P {color:blue}
</STYLE>
See Also

imports, link, style, styleSheet

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
@charset Rule DHTML Properties
Web Workshop | DHTML, HTML & CSS
!important Declaration
Increases the weight or importance of a particular rule.

Syntax

HTML { sAttribute:sValue!important }
Scripting N/A

Possible Values

sAttribute Any cascading style sheets (CSS) attribute.


sValue Any of the range of values available to the corresponding attribute.

The declaration has no default value.

Expressions can be used in place of the preceding value(s), as of


Microsoft® Internet Explorer 5. For more information, see
dynamic properties .
I
Example

This example includes the !important declaration in the style


rule. The color of the text normally would be green, because
inline styles overrule the rules set in a style tag. By including the
!important declaration in the style rule, the content of the
paragraph is instead set to red.

<STYLE>
P {color:red!important}
</STYLE>
<P STYLE="color:green">This will be red.</P>

Applies To

A, ADDRESS, B, BIG, BLOCKQUOTE, BODY, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, DD, DFN, DIR,
DIV, DL, DT, EM, FIELDSET, FORM, Hn, HTML, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT
type=file, INPUT type=hidden, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT
type=reset, INPUT type=submit, INPUT type=text, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OL,
P, PLAINTEXT, PRE, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD,
TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
line-height Attribute | l... LINK Attribute | link P
Web Workshop | DHTML, HTML & CSS
link Pseudo-class
Sets or retrieves the style of the <A> element for the default state of the link.

Syntax

HTML [A]:link { attribute1:parameter1 [; attribute2:parameter2 [; . . .]] }


Scripting N/A

Possible Values

attribute Any attribute applicable to text.


parameter Any of the range of values available to the corresponding attribute.

The pseudo-class is read/write with a browser-specific default.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The link pseudo-class often is set with specific styles for the other states—active,
visited, and hover—of a link.

Internet Explorer 3.0 applies the link pseudo-class value to the visited psuedo-class.

Example

This example uses the link pseudo-class.

<STYLE>
A:link{ color: #FF0000 } // unvisited link
A:visited { color: #CFCFCF } // visited links
</STYLE>

Applies To

See Also

hover, visited

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
visibility Attribute | vi... VLINK ATTRIBUTE | vL
Web Workshop | DHTML, HTML & CSS
visited Pseudo-class
Sets the style of the anchor for previously visited links.

Syntax

HTML [A]:visited { attribute1:parameter1 [; attribute2:parameter2 [; . . .]] }


Scripting N/A

Possible Values

attribute Any attribute applicable to text.


parameter Any of the range of values available to the corresponding attribute.

The default value is browser-specific.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The visited pseudo-class often is used with the active, link, and hover pseudo-
elements to define the various states of a link.

Using pseudo-classes on elements other than the A element has no effect.

Example

This example sets unvisited links to red and visited links to blue, and uses a colon (:)
to specify a pseudo-class.

:link { color: red } // unvisited link


:visited { color: blue } // visited links

Applies To

HTML A
Scripting N/A

See Also

active, hover, link

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
cloneNode Method close Method DHTML Meth
Web Workshop | DHTML, HTML & CSS
close Method
Closes the current browser window or HTML Application (HTA).

Syntax

window.close()

Return Value

No return value.

Remarks

The way that you close a window programmatically determines whether the user gets
prompted. If you invoke the close method on a window that you did not open with
script, the user sees a confirm dialog box. This also happens if you use close to exit
the last running instance of Microsoft® Internet Explorer. You can only use the close
method silently with HTAs. In the case of HTAs, the application is trusted and follows a
different security model.

When a function fired by an event on the BODY object calls the close method, the
window.close method is implied. When an event on the BODY object calls the close
method, the document.close method is implied.

Applies To

window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
top Attribute | top Prope... top Property DHTM
Web Workshop | DHTML, HTML & CSS
top Property
Retrieves the topmost ancestor window, which is its own parent.

Syntax

HTML N/A
Scripting [ oTop = ] window.top

Possible Values

oTop String that specifies the topmost parent window.

The property is read-only with no default value.

Applies To

HTML N/A
Scripting window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
selectorText Property SHAPE Attribute | shape
Web Workshop | DHTML, HTML & CSS
self Property
Retrieves a reference to the current window or frame.

Syntax

HTML N/A
Scripting [ oSelf = ] object.self

Possible Values

oSelf Object that specifies the current window or frame.

The property is read-only with no default value.

Remarks

You can use the property to explicitly refer to the current window or frame. To improve
scripting efficiency, you also can use it to make implicit window references explicit.

Applies To

FRAME, window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
recordset Property REL Attribute | rel Prope...
Web Workshop | DHTML, HTML & CSS
referrer Property
Retrieves the URL of the location that referred the user to the current page.

Syntax

HTML N/A
Scripting [ sUrl= ] document.referrer

Possible Values

sUrl String that specifies the URL of the referring page.

The property is read-only with no default value.

Remarks

This property returns a value only when the user reaches the current page through a
link from the previous page. Otherwise, document.referrer returns an empty string;
it also returns an empty string when the link is from a secure site.

For example, if PageA.htm includes a link to PageB.htm, and the user clicks that link,
the document.referrer on PageB.htm returns "PageA.htm". However, if the user is on
PageA.htm and types PageB.htm into the address line or uses Open in the File menu to
get to PageB.htm, the document.referrer returns an empty string.

Applies To

HTML N/A
Scripting document

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onLine Property outerHTML Property DHTML P
Web Workshop | DHTML, HTML & CSS
opener Property
Sets or retrieves a reference to the window that created the current window.

Syntax

HTML N/A
Scripting window.opener [ =sWindow ]

Possible Values

sWindow String that specifies the window reference.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Applies To

HTML N/A
Scripting window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
href Property HREF Attribute | href Pro... DHT
Web Workshop | DHTML, HTML & CSS
HREF Attribute | href Property
Sets or retrieves the destination URL or anchor point.

Syntax

HTML <ELEMENTHREF = sURL ... >


Scripting object.href [ =sURL ]

Possible Values

sURL String that specifies the URL or anchor point.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

HREF attributes on anchors can be used to jump to bookmarks or any object's


identification attribute.

When an anchor is specified, the link to that address is represented by the text
between the opening and closing anchor tags.

Applies To

A, AREA, LINK

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
NAME Attribute | name Pro... nameProp Proper
Web Workshop | DHTML, HTML & CSS
NAME Attribute | name Property
Sets or retrieves the name of the control, bookmark, or application.

Syntax

HTML <ELEMENT NAME = sName ... >


Scripting object.name [ = sName ]

Possible Values

sName String that specifies the name.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

When submitting a FORM, use the name property to bind the value of the control. The
name is not the value displayed for the button, reset, and submit input types. The
internally stored value, not the displayed value, is the one submitted with the form.

Microsoft® JScript® (compatible with ECMA 262 language specification) allows the
name to be changed at run time. This does not cause the name in the programming
model to change in the collection of elements, but it does change the name used for
submitting elements.

In Internet Explorer 5, the name property cannot be set at run time on anchor objects
dynamically created with the createElement method. To create an anchor with a
NAME attribute, include the attribute and value when using the createElement
method, or use the innerHTML property.

Example

This example sets the NAME attribute on a dynamically created anchor.

var oAnchor = document.createElement("<A NAME='AnchorName'>


</A>");

Applies To

A, APPLET, BUTTON, FORM, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, LINK, MAP, OBJECT, PARAM, RT, RUBY, SELECT,
TEXTAREA

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
A Element | A Object Members
Designates the start or destination of a hypertext link.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle ,
dataFld , dataSrc , dir , firstChild , hash , host ,
hostname , href , id , innerHTML , innerText , isTextEdit
, lang , language , lastChild , Methods , name ,
nameProp , nextSibling , nodeName , nodeType ,
nodeValue , offsetHeight , offsetLeft , offsetParent ,
offsetTop , offsetWidth , outerHTML , outerText ,
parentElement , parentNode , parentTextEdit ,
pathname , port , previousSibling , protocol ,
readyState , recordNumber , rel , rev , runtimeStyle ,
scopeName , scrollHeight , scrollLeft , scrollTop ,
scrollWidth , search , sourceIndex , style , tabIndex ,
tagName , tagUrn , target , title , uniqueID , urn

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforeeditfocus ,


onbeforepaste , onblur , onclick , oncontextmenu ,
oncopy , oncut , ondblclick , ondrag , ondragend ,
ondragenter , ondragleave , ondragover , ondragstart ,
ondrop , onfocus , onhelp , onkeydown , onkeypress ,
onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onresize , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

anchor , clientCaps , download , homePage , httpFolder


, saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthpadding-rightpaddingcursorvisibilityfont-styletext-
autospaceleftoverflow-xfont-variantoverflow-
ylinkbackgrounddirectionpositionbackground-
positionclearvisitedword-spacingtoppadding-
lefthoverlayout-grid-modepadding-bottomrightfont-
sizeoverflowletter-spacingdisplayfloatfont-
familyactivebehaviorbackground-repeattext-
transformbackground-imagebottomcliptext-
decorationcolorz-indexfontfont-weightbackground-
colorunicode-bidiline-heightlayout-gridpadding-top
Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
ACRONYM Element | ACRONYM Object
Members
Indicates an acronym abbreviation.

Properties

accessKey , canHaveChildren , className , currentStyle


, dir , firstChild , id , innerHTML , innerText , isTextEdit ,
lang , language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , sourceIndex , style ,
tabIndex , tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , cloneNode ,
componentFromPoint , detachEvent , focus ,
getAdjacentText , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement , insertBefore ,
mergeAttributes , removeBehavior , removeChild ,
removeExpression , removeNode , replaceAdjacentText ,
replaceChild , replaceNode , setExpression , swapNode

Events

onblur , ondrag , ondragend , ondragenter ,


ondragleave , ondragover , ondragstart , ondrop ,
onfocus , onkeydown , onkeypress , onkeyup ,
onreadystatechange , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthdirectionoverflowpadding-
rightdisplaypaddingunicode-bidibehaviorpadding-
leftlayout-gridlayout-grid-modetext-autospacepadding-
topoverflow-xpadding-bottomoverflow-y

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
ADDRESS Element | ADDRESS Object
Members
Specifies information, such as address, signature, and
authorship, of the current document.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviorword-breaktext-
transformbackground-repeatbackground-
imagebottomvisibilityfont-stylecliptext-
autospaceleftoverflow-xfont-varianttext-
decorationoverflow-yline-
breakbackgroundcolordirectionz-indextext-
justifypositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright
Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
APPLET Element | APPLET Object Members
Places executable content on the page.

Properties

accessKey , align , altHTML , className , clientHeight ,


clientLeft , clientTop , clientWidth , codeBase ,
currentStyle , dataFld , dataSrc , disabled , firstChild ,
hspace , id , isTextEdit , lang , language , lastChild ,
name , nextSibling , nodeName , nodeType , nodeValue
, offsetHeight , offsetLeft , offsetParent , offsetTop ,
offsetWidth , outerHTML , outerText , parentElement ,
parentNode , parentTextEdit , previousSibling ,
readyState , recordNumber , runtimeStyle , scopeName
, scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , src , style , tabIndex , tagName , tagUrn ,
title , uniqueID , vspace

Methods

addBehavior , applyElement , attachEvent , blur ,


clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName ,
hasChildNodes , insertAdjacentElement ,
mergeAttributes , namedRecordset , releaseCapture ,
removeAttribute , removeBehavior , removeExpression ,
replaceAdjacentText , scrollIntoView , setAttribute ,
setCapture , setExpression , swapNode

Events
onbeforecut , onbeforeeditfocus , onbeforepaste , onblur
, oncellchange , onclick , oncontextmenu , oncut ,
ondataavailable , ondatasetchanged ,
ondatasetcomplete , ondblclick , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onload ,
onlosecapture , onmousedown , onmousemove ,
onmouseout , onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onrowenter , onrowexit , onrowsdelete , onrowsinserted
, onscroll

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage

Styles

widthfont-sizeoverflowpadding-
rightfloatdisplaypaddingcursorbehaviorbottomvisibilitycli
ptext-autospaceleftoverflow-xoverflow-ycolorz-
indexpositioncleartoppadding-leftlayout-gridlayout-grid-
modeheightpadding-toppadding-bottomright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
cookieEnabled Property cpuClass Property DH
Web Workshop | DHTML, HTML & CSS
COORDS Attribute | coords Property
Sets or retrieves the coordinates of a hyperlink AREA within an image MAP.

Syntax

HTML <AREA COORDS = sCoords ... >


Scripting object.coords [ = sCoords ]

Possible Values

sCoords String that specifies the coordinates. The format of this string depends on the value of the SHAPE attribute of the AREA element. For
details, see the Remarks section.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The format of sCoords depends on the value of the SHAPE attribute as follows:

SHAPE= "circ" or COORDS= "x1,y1,r" – Where x1,y2 are the coordinates of the center of the circle, and r is the radius of the circle.
"circle"
SHAPE= "poly" or COORDS= "x1,y1,x2,y2...xn,yn" – Where each x,y pair contains the coordinates of one vertex of the polygon.
"polygon"
SHAPE= "rect" or COORDS= "x1,y1,x2,y2" – Where x1,y1 are the coordinates of the upper-left corner of the rectangle and x2,y2 are the
"rectangle" coordinates of the lower-right coordinates of the rectangle.

Example

This example provides the full code for an image map of the solar system. Clicking on
the sun or any planet links to an individual image. The user can click the Back button
from the image to return to the solar system image map.

Applies To

AREA

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
self Property shiftKey Property DHTML Proper
Web Workshop | DHTML, HTML & CSS
SHAPE Attribute | shape Property
Sets or retrieves the shape of a hyperlink AREA in an image MAP.

Syntax

HTML <AREA SHAPE = sShape ... >


Scripting area.shape [ = sShape ]

Possible Values

sShape String that specifies one of the following values:


circ Circle.
circle Circle.
poly Polygon.
polygon Polygon.
rect Rectangle.
rectangle Rectangle.

The property is read/write with no default value.

The value of the SHAPE attribute determines the format of the COORDS attribute.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Example

This example provides the full code for an image map of the solar system. When you
click on the sun or any planet, you will link to the image associated with the x,y
coordinate. You can click the Back button from the image to return to the solar system
image map.

Applies To

AREA

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
AREA Element | AREA Object Members
Defines the shape, coordinates, and associated URL of one
hyperlink region within a client-side image MAP.

Properties

accessKey , alt , className , coords , currentStyle , dir


, firstChild , hash , host , hostname , href , id ,
isTextEdit , lang , language , lastChild , nextSibling ,
nodeName , nodeType , nodeValue , noHref ,
offsetHeight , offsetLeft , offsetParent , offsetTop ,
offsetWidth , outerHTML , outerText , parentElement ,
parentNode , parentTextEdit , pathname , port ,
previousSibling , protocol , readyState , recordNumber ,
runtimeStyle , scopeName , search , shape ,
sourceIndex , style , tabIndex , tagName , tagUrn ,
target , title , uniqueID

Methods

addBehavior , applyElement , attachEvent , blur ,


clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeExpression ,
replaceAdjacentText , scrollIntoView , setAttribute ,
setCapture , setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforeeditfocus ,
onbeforepaste , onblur , onclick , oncontextmenu ,
oncopy , oncut , ondblclick , ondrag , ondragend ,
ondragenter , ondragleave , ondragover , ondragstart ,
ondrop , onfocus , onhelp , onkeydown , onkeypress ,
onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthdirectionunicode-bidibehaviorlayout-gridlayout-
grid-modetext-autospace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
areas Collection behaviorUrns Collection DHT
Web Workshop | DHTML, HTML & CSS
attributes Collection
Retrieves a collection of attributes of the object.

Syntax

[ collAttributes = ] object.attributes
[ oObject = ] object.attributes(iIndex)

Possible Values

collAttributes Zero-based array of attributes applied to the object.


oObject Reference to an individual attribute in the array of attributes assigned to the object.
iIndex Required. Integer that indicates the zero-based index of the item to be returned.

Members

Remarks

The attributes collection does not include expando properties. To access the expando
properties of an object, use the JScript® (compatible with ECMA 262 language
specification) for...in construct.

The attributes collection does not expose the style object. Use the cssText property of
the object's style property to retrieve the persistent representation of the cascading
styles associated with an object.

Unlike other DHTML collections, such as all and children, the attributes collection is
static. Modifications to the properties of an object are not automatically reflected by an
existing reference to the attributes collection of that object.

Example

This example shows how to iterate through the collection of attributes of the specified
object, displaying the name and value of the attributes as well as the language of the
attribute (HTML or script).

<SCRIPT>
function ShowAttribs(oElem)
{
txtAttribs.innerHTML = '';

// Retrieve the collection of attributes for the specified


object.
var oAttribs = oElem.attributes;

// Iterate through the collection.


for (var i = 0; i < oAttribs.length; i++)
{
var oAttrib = oAttribs[i];

// Print the name and value of the attribute.


// Additionally print whether or not the attribute was
specified
// in HTML or script.
txtAttribs.innerHTML += oAttrib.nodeName + '=' +
oAttrib.nodeValue + ' (' + oAttrib.specified + ')
<BR>';
}
}
</SCRIPT>

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BGSOUND, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE,
CODE, COL, COLGROUP, COMMENT, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn, HR,
HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, KBD, LABEL, LEGEND, LI, LINK, LISTING, MAP,
MARQUEE, MENU, NEXTID, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, S, SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP,
TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
EVENT Attribute | event P... FACE Attribute | fa
Web Workshop | DHTML, HTML & CSS
expando Property
Sets or retrieves whether arbitrary variables can be created within an object.

Syntax

HTML N/A
Scripting document.expando [ =bExpand ]

Possible Values

bExpand Boolean that specifies one of the following values:


true Creation of arbitrary variables is allowed.
false Creation of arbitrary variables is not allowed.

The property is read/write with a default value of true.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

You can extend the properties on an object by creating arbitrary properties with
values. You should be careful, however, because you can unintentionally set a property
value when scripting in a case-sensitive language such as Microsoft® JScript®
(compatible with ECMA 262 language specification). For example, if the property value
is borderColor and you type the value "bordercolor = 'blue'", you have, in fact, created
another property on the style object called bordercolor with the value 'blue'. If you
query the value of the property, the value "blue" is returned. However, the borders for
the element do not turn blue.

Microsoft® Visual Basic® Scripting Edition (VBScript) does not support expando
properties on its native language objects, nor does it cause Microsoft® Internet
Explorer to create expando properties on its objects. Internet Explorer supports
creation of expando properties on its objects, in any language, through setAttribute.

Applies To

HTML N/A
Scripting document

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
Attribute Object Members
Represents an attribute or property of an HTML element as
an object.

Properties

nodeName , nodeType , nodeValue , specified

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
SPAN Attribute | span Pro... S SRC Attribute | src
Web Workshop | DHTML, HTML & CSS
specified Property
Retrieves whether an attribute has been specified.

Syntax

HTML N/A
Scripting [ bSpecified = ] object.specified

Possible Values

bSpecified Boolean that specifies one of the following values:


true Attribute is specified.
false Attribute is not specified.

The property is read-only with no default value.

Remarks

An attribute is specified if it is set through HTML or script.

Example

This example uses the specified property to determine the attributes set for an
object. The function checks each attribute, and lists all of the attributes of the object
and the value of each attribute. In addition, each attribute that is set is displayed.

<SCRIPT>
function fnFindSpecified(){
var oAttributes=oList.attributes;
alert(oAttributes(0).nodeName);
for(var i=0;i<oAttributes.length;i++){
var oNode=document.createElement("LI");
var oNodeValue=document.createTextNode(i + " "
+ oAttributes(i).nodeName + " = "
+ oAttributes(i).nodeValue);
oList.appendChild(oNode);
oNode.appendChild(oNodeValue);
if(oAttributes(i).nodeValue!=null){
alert(oAttributes(i).nodeName
+ " specified: " + oAttributes(i).specified);
}
}
}
</SCRIPT>

<UL ID = oList onclick = "fnFindSpecified()">


<LI>Click to Find Specified Attributes
</UL>
Applies To

Attribute

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
B Element | B Object Members
Specifies that the text should be rendered in bold.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagebottomvisibilityfont-
stylecliptext-autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
BASE Element | BASE Object Members
Specifies an explicit URL used to resolve links and
references to external sources such as images and style
sheets.

Properties

currentStyle , firstChild , href , id , isTextEdit , lastChild


, nextSibling , nodeName , nodeType , nodeValue ,
parentElement , parentNode , parentTextEdit ,
previousSibling , readyState , runtimeStyle ,
scopeName , sourceIndex , style , tagName , tagUrn ,
target , uniqueID

Methods

addBehavior , applyElement , attachEvent ,


clearAttributes , cloneNode , componentFromPoint ,
contains , detachEvent , getAdjacentText , getAttribute ,
getBoundingClientRect , getClientRects ,
getElementsByTagName , hasChildNodes ,
insertAdjacentElement , mergeAttributes ,
removeAttribute , removeBehavior ,
replaceAdjacentText , setAttribute , swapNode

Events

onreadystatechange

Collections

all , attributes , behaviorUrns , childNodes , children


Behaviors

clientCaps , download , homePage

Styles

widthbehaviorlayout-gridlayout-grid-modetext-
autospace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
BASEFONT Element | BASEFONT Object
Members
Sets a base font value to be used as the default font when
rendering text.

Properties

color , currentStyle , face , firstChild , id , isTextEdit ,


lastChild , nextSibling , nodeName , nodeType ,
nodeValue , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
runtimeStyle , scopeName , size , sourceIndex , style ,
tagName , tagUrn , uniqueID

Methods

addBehavior , applyElement , attachEvent ,


clearAttributes , cloneNode , componentFromPoint ,
contains , detachEvent , getAdjacentText , getAttribute ,
getBoundingClientRect , getClientRects ,
getElementsByTagName , hasChildNodes ,
insertAdjacentElement , insertAdjacentHTML ,
insertAdjacentText , mergeAttributes , removeAttribute ,
removeBehavior , replaceAdjacentText , setAttribute ,
swapNode

Events

onreadystatechange

Collections

all , attributes , behaviorUrns , childNodes , children


Behaviors

clientCaps , download , homePage

Styles

widthfont-familybehaviorlayout-gridlayout-grid-
modetext-autospace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
dialogWidth Property DIRECTION Attribute | dir
Web Workshop | DHTML, HTML & CSS
DIR Attribute | dir Property
Sets or retrieves the reading order of the object.

Syntax

HTML <ELEMENTDIR = sDir ... >


Scripting object.dir [ =sDir ]

Possible Values

sDir String that specifies one of the following values:


ltr Text flow is left-to-right.
rtl Text flow is right-to-left.

The property is read/write with a default value of ltr.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Applies To

A, ACRONYM, ADDRESS, AREA, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD, DEL,
DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, Hn, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT
type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, KBD, LABEL, LEGEND, LI,
LISTING, MAP, MARQUEE, MENU, NOBR, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL, SPAN, STRIKE,
STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

direction

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
BDO Element | BDO Object Members
Allows authors to disable the bidirectional algorithm for
selected fragments of text.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , scopeName ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , tabIndex , tagName , tagUrn , title

Methods

appendChild , applyElement , blur , clearAttributes ,


cloneNode , componentFromPoint , focus ,
getAdjacentText , getElementsByTagName ,
getExpression , hasChildNodes , insertAdjacentElement
, insertBefore , mergeAttributes , removeChild ,
removeExpression , removeNode , replaceAdjacentText ,
replaceChild , replaceNode , setExpression , swapNode

Events

onafterupdate , onbeforecopy , onbeforecut ,


onbeforepaste , onbeforeupdate , onblur , oncellchange
, onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onerrorupdate ,
onfilterchange , onfocus , onhelp , onkeydown ,
onkeypress , onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onscroll , onselectstart

Collections

all , attributes , childNodes , children , filters

Behaviors

clientCaps , download , homePage

Styles

directionoverflowpositionpadding-
rightdisplaypaddingunicode-bidipadding-leftlayout-
gridcliplayout-grid-modepadding-toptext-
autospaceoverflow-xpadding-bottomoverflow-y

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
BGSOUND Element | BGSOUND Object
Members
Enables pages with background sounds or soundtracks to be
created.

Properties

balance , currentStyle , id , loop , nextSibling ,


nodeName , nodeType , nodeValue , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , runtimeStyle ,
scopeName , sourceIndex , src , style , tagName ,
tagUrn , uniqueID , volume

Methods

addBehavior , applyElement , attachEvent ,


clearAttributes , cloneNode , componentFromPoint ,
detachEvent , getAttribute , getElementsByTagName ,
insertAdjacentElement , mergeAttributes ,
removeAttribute , removeBehavior , setAttribute ,
swapNode

Events

onreadystatechange

Collections

all , attributes , behaviorUrns

Behaviors
clientCaps , download , homePage

Styles

behaviortext-autospace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
BIG Element | BIG Object Members
Specifies that the enclosed text should be displayed in a
larger font than the current font.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagebottomvisibilityfont-
stylecliptext-autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright
Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
BLOCKQUOTE Element | BLOCKQUOTE
Object Members
Sets apart a quotation in text.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modepadding-bottomrightfont-
sizeborder-bottomoverflowletter-
spacingdisplayfloatfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
onbeforeupdate Event onbounce Event DHTM
Web Workshop | DHTML, HTML & CSS
onblur Event
Fires when the object loses the input focus.

Syntax

Inline HTML <ELEMENT onblur = "handler" ... > All platforms


Event property object.onblur = handler JScript (compatible with ECMA 262 language specification) and VBScript
Named script <SCRIPT FOR = object EVENT = onblur> Internet Explorer only

Remarks

Bubbles No
Cancels No
To invoke Cause an object to lose focus:
Click the mouse on the document background or another control.
Use the keyboard to navigate from one object to the next.
Invoke the blur method when an object has focus.
Switch focus to a different application or open a second browser window.

Default action Switches focus away from the object on which the event is fired.

The onblur event fires on the original object before the onfocus or onclick event fires
on the object that is receiving focus. Where applicable, the onblur event fires after the
onchange event.

Use the focus events to determine when to prepare an object to receive or validate
input from the user.

As of Microsoft® Internet Explorer 5, you must set the TABINDEX attribute of elements
that expose the onblur event.

Event Object Properties

Although event handlers in the document object model do not receive parameters
directly, the handler can query the event object for data.

Example

This example shows how to display the name of the object that has lost focus—that is,
the object that fires the onblur event.

<HTML>
<BODY>
<INPUT TYPE=text NAME=txtFName VALUE="First Name"
onblur="alert(event.srcElement.name)">
<INPUT TYPE=text NAME=txtLName VALUE="Last Name"
onblur="alert(event.srcElement.name)">
<INPUT TYPE=text NAME=txtPhone VALUE="Phone"
onblur="alert(event.srcElement.name)">
</BODY>
</HTML>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BDO, BIG, BLOCKQUOTE, BUTTON, CAPTION, CENTER, CITE, custom, DD, DEL, DFN, DIR, DIV, DL, DT,
EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file,
INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, ISINDEX, KBD,
LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG,
SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, window, XMP

See Also

blur, focus

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onfinish Event onhelp Event DHTML Events
Web Workshop | DHTML, HTML & CSS
onfocus Event
Fires when the object receives the focus.

Syntax

Inline HTML <ELEMENT onfocus = "handler" ... > All platforms


Event property object.onfocus = handler JScript (compatible with ECMA 262 language specification) only
Named script <SCRIPT FOR = object EVENT = onfocus> Internet Explorer only

Remarks

Bubbles No
Cancels No
To invoke Give focus to an object:
Click an object.
Use keyboard navigation.
Invoke the focus method.

Default action Sets focus to an object.

When one object loses focus and another object receives focus, the onfocus event
fires on the object receiving focus only after the onblur event fires on the object
losing focus. Use the focus events to determine when to prepare an object to receive
input from the user.

As of Microsoft® Internet Explorer 5, you can force elements that do not implicitly
receive focus to receive focus by adding them to the document tabbing order using
the TABINDEX attribute.

Elements cannot receive focus until the document is finished loading.

As of Internet Explorer 5, elements retain focus within the current browser history
when the user returns to a page. To avoid firing the onfocus event unintentionally for
an element when the document loads, invoke the focus method on another element.

Event Object Properties

Although event handlers in the document object model do not receive parameters
directly, the handler can query the event object for data.

Example

This example uses the onfocus event to make INPUT_text and LABEL objects more
accessible. When the INPUT_text object has focus, the onfocus event fires and the
backgroundColor, fontSize, and fontWeight properties are changed to give the control
more prominence.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BDO, BIG, BLOCKQUOTE, BUTTON, CAPTION, CENTER, CITE, custom, DD, DEL, DFN, DIR, DIV, DL,
DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, Hn, HR, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT
type=file, INPUT type=hidden, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT
type=text, INS, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT,
SMALL, SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, window, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onkeyup Event onlosecapture Event DHTML E
Web Workshop | DHTML, HTML & CSS
onload Event
Fires immediately after the browser loads the object.

Syntax

Inline HTML <ELEMENT onload = "handler" ... > All platforms


Event property object.onload = handler JScript (compatible with ECMA 262 language specification) only
Named script <SCRIPT FOR = object EVENT = onload> Internet Explorer only

Remarks

Bubbles No
Cancels No
To invoke Open a page in the browser to invoke this event for the document or any object within it.
Default action Loads the object for which the event is specified.

The browser loads applications, embedded objects, and images as soon as it


encounters the APPLET, EMBED, and IMG objects during parsing. Consequently, the
onload event for these objects occurs before the browser parses any subsequent
objects. To ensure that an event handler receives the onload event for these objects,
place the SCRIPT object that defines the event handler before the object and use the
onload attribute in the object to set the handler.

The onload attribute of the BODY object sets an onload event handler for the
window. This technique of calling the window onload event through the BODY object
is overridden by any other means of invoking the window onload event, provided the
handlers are in the same script language.

Event Object Properties

Although event handlers in the DHTML Object Model do not receive parameters
directly, the handler can query the event object for data.

Example

This example uses an onload event handler to display a message in the window's
status bar when the page has finished loading.

<BODY>
<SCRIPT FOR=window EVENT=onload LANGUAGE="JScript">
window.status = "Page is loaded!";
</SCRIPT>
</BODY>

This example sets an onload event handler for an IMG object. The handler uses the
event object to retrieve the URL of the image.
<SCRIPT>
function imageLoaded()
{
window.status = "Image " + event.srcElement.src + " is
loaded";
}
</SCRIPT>
<BODY>
<IMG SRC="sample.gif" onload="imageLoaded()">
</BODY>

Applies To

APPLET, EMBED, FRAMESET, IMG, LINK, SCRIPT, window

See Also

onreadystatechange, onunload

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onsubmit Event DHTML Events
Web Workshop | DHTML, HTML & CSS
onunload Event
Fires immediately before the object is unloaded.

Syntax

Inline HTML <ELEMENT onunload = "handler" ... All platforms


>
Event object.onunload = handler JScript (compatible with ECMA 262 language
property specification) only
Named <SCRIPT FOR = object EVENT = Internet Explorer only
script onunload>

Remarks

Bubbles No
Cancels No
To
invoke Close the current browser window.
Navigate to another location by entering a new address or selecting a Favorite.
Click the Back, Forward, Refresh, or Home button.
Click on an anchor that refers the browser to another Web page.
Invoke the anchor click method.
Invoke the document write method.
Invoke the document open method.
Invoke the document close method.
Invoke the window close method.
Invoke the window open method, providing the possible value _self for the
window name.
Invoke the window navigate or NavigateAndFind method.
Invoke the location replace method.
Invoke the location reload method.
Specify a new value for the location href property.
Submit a FORM to the address specified in the ACTION attribute via the
INPUT_submit control, or invoke the form submit method.

Default Removes the object or document from the browser window.


action

Event Object Properties

Although event handlers in the DHTML Object Model do not


receive parameters directly, the handler can query the event
object for data.
Example

This example shows how to use the onunload event to run


script when the window object has been unloaded.

<HEAD>
<SCRIPT FOR=window EVENT=onunload>
alert("The onunload event fired for the
window object.");
</SCRIPT>

<SCRIPT>
function fnRelocate()
{

location.href="/workshop/samples/author/dhtml
/refs/onunloadEX_target.htm";
}
</SCRIPT>
</HEAD>
<BODY>
<INPUT TYPE=button VALUE="Go To Page 2"
onclick="fnRelocate()">
<IMG ID=imgTest
SRC="/workshop/graphics/prop_rw.gif">
</BODY>

This feature requires Internet Explorer 4.0 or later. Click the


icon below to install the latest version. Then reload this page
to view the sample.

Applies To

FRAMESET, window
See Also

onload

Did you find this topic useful? Suggestions for other topics? write
us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
BODY Element | body Object Members
Specifies the beginning and end of the document body.

Properties

accessKey , aLink , background , bgColor , bgProperties


, bottomMargin , canHaveChildren , className ,
clientHeight , clientLeft , clientTop , clientWidth ,
currentStyle , dataFld , dataFormatAs , dataSrc , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , leftMargin , link , nextSibling ,
nodeName , nodeType , nodeValue , noWrap ,
offsetHeight , offsetLeft , offsetParent , offsetTop ,
offsetWidth , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
rightMargin , runtimeStyle , scopeName , scroll ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , style , tabIndex , tagName , tagUrn , text
, title , topMargin , uniqueID , vLink

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , createControlRange ,
createTextRange , detachEvent , doScroll , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , setAttribute , setCapture , setExpression ,
swapNode

Events

onafterprint , onbeforecut , onbeforepaste ,


onbeforeprint , onclick , oncontextmenu , oncut ,
ondblclick , ondrag , ondragend , ondragenter ,
ondragleave , ondragover , ondragstart , ondrop ,
onfilterchange , onkeydown , onkeypress , onkeyup ,
onlosecapture , onmousedown , onmousemove ,
onmouseout , onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onscroll ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children ,


filters

Behaviors

clientCaps , download , homePage , httpFolder

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursorfiltertext-indentvisibilityfont-
styleborder-left-colormargin-lefttext-autospaceoverflow-
xlayout-grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifybackground-positionborder-right-
colorborder-rightword-spacingpadding-leftlayout-grid-
modepadding-bottomfont-sizeborder-
bottomoverflowletter-spacingdisplayfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagetext-decorationcolorborder-styleborder-top-
widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthbackground-
attachmentborder-leftpadding-topborder-colorborder-
right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
BR Element | BR Object Members
Inserts a line break.

Properties

className , clear , currentStyle , id , isTextEdit ,


nextSibling , nodeName , nodeType , nodeValue ,
offsetHeight , offsetLeft , offsetParent , offsetTop ,
offsetWidth , outerHTML , outerText , parentElement ,
parentNode , parentTextEdit , previousSibling ,
readyState , recordNumber , runtimeStyle , scopeName
, sourceIndex , style , tagName , tagUrn , uniqueID

Methods

addBehavior , applyElement , attachEvent ,


clearAttributes , cloneNode , componentFromPoint ,
detachEvent , getAdjacentText , getAttribute ,
getElementsByTagName , getExpression ,
hasChildNodes , insertAdjacentElement ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeExpression ,
replaceAdjacentText , scrollIntoView , setAttribute ,
setCapture , setExpression , swapNode

Events

onlosecapture , onreadystatechange

Collections

attributes , behaviorUrns

Behaviors
clientCaps , download , homePage

Styles

widthbehaviorlayout-gridlayout-grid-modetext-
autospace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
value Property VALUE Attribute | value P... DH
Web Workshop | DHTML, HTML & CSS
VALUE Attribute | value Property
Sets or retrieves the value of the object.

Syntax

HTML <ELEMENT VALUE = sValue ... >


Scripting object.value [ = sValue ]

Possible Values

sValue String that specifies the value of an object or a FORM control. The purpose of the string depends on the type of control, as follows:
checkbox The selected value. The control submits this value only if the user has selected the control. Otherwise,
the control submits no value.
file The value, a file name, typed by the user into the control. Unlike other controls, this value is read-only.
hidden The control submits this value when the form is submitted.
OPTION The selected value. The containing list box control submits this value only if the user has selected the
option.
password The default value. The control displays this value when it is first created and when the user clicks the
reset button.
radio The button label. If not set, the label defaults to "Reset".
reset The selected value. The control submits this value only if the user has selected the control. Otherwise,
the control submits no value.
submit The button label. If not set, the label defaults to "Submit Query."
text The default value. The control displays this value when it is first created and when the user clicks the
reset button.

This property is read/write with a default value of on for the checkbox and radio
objects, Submit Query for the submit object, and Reset for the reset object. All
other objects have no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The VALUE attribute of the PARAM object specifies a value passed to an APPLET,
EMBED, or OBJECT object.

Example

This example sets the value for each option to an integer string (for example, a part
number).

<SELECT>
<OPTION VALUE="123">Item One
<OPTION VALUE="456">Item Two
<OPTION VALUE="789">Item Three
</SELECT>

Applies To
BUTTON, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT type=password, INPUT
type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, OPTION, PARAM

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
innerHTML Property ISMAP Attribute | isMap P..
Web Workshop | DHTML, HTML & CSS
innerText Property
Sets or retrieves the text between the start and end tags of the object.

Syntax

HTML N/A
Scripting object.innerText [ = sTxt ]

Possible Values

sTxt String that specifies the text between the start and end tags.

The property is read/write with no default value (see Remarks).

Remarks

The innerText property is read-only on the HTML, TABLE, TBODY, TFOOT, THEAD, and
TR objects.

When the innerText property is set, the given string completely replaces the existing
content of the object.

You can set this property only after the onload event fires on the window. When
dynamically creating a tag using TextRange, innerHTML, or outerHTML, use Microsoft®
JScript® (compatible with ECMA 262 language specification) to create new events to
handle the newly formed tags. Microsoft® Visual Basic® Scripting Edition (VBScript) is
not supported.

You can change the value of the TITLE element using the document.title property.

To change the contents of the TABLE, TFOOT, THEAD, and TR elements, use the
table object model. For example, use the rowIndex property or the rows collection to
retrieve a reference to a specific table row. You can add or delete rows using the
insertRow and deleteRow methods. To retrieve a reference to a specific cell, use the
cellIndex property or the cells collection. You can add or delete rows using the
insertCell and deleteCell methods. To change the content of a particular cell, use the
innerHTML property.

Example

This example uses the innerText property to replace an object's contents. The object
surrounding the text is not replaced.

<P ID=oPara>Here's the text that will change.</P>


:
<BUTTON onclick="oPara.innerText='WOW! It changed!'">Change
text</BUTTON>
<BUTTON onclick="oPara.innerText='And back
again'">Reset</BUTTON>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, custom, DD, DEL, DFN, DIR, EM, FIELDSET,
FONT, FORM, HEAD, Hn, HTML, I, IFRAME, INS, KBD, LABEL, LEGEND, LI, LISTING, MAP, MARQUEE, MENU, NEXTID, NOBR, OL, OPTION, P,
PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, STYLE, SUB, SUP, TABLE, TBODY, TD, TEXTAREA,
TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR, XMP, XMP

See Also

insertAdjacentText

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
BUTTON Element | BUTTON Object
Members
Specifies a container for rich HTML that is rendered as a
button.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle ,
dataFld , dataFormatAs , dataSrc , dir , disabled ,
firstChild , form , id , innerHTML , innerText , isTextEdit
, lang , language , lastChild , name , nextSibling ,
nodeName , nodeType , nodeValue , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
outerHTML , outerText , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
recordNumber , runtimeStyle , scopeName ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , style , tabIndex , tagName , tagUrn , title
, type , uniqueID , value

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , createTextRange ,
detachEvent , focus , getAdjacentText , getAttribute ,
getBoundingClientRect , getClientRects ,
getElementsByTagName , getExpression ,
hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events

onbeforecut , onbeforeeditfocus , onbeforepaste , onblur


, onclick , oncontextmenu , oncut , ondblclick ,
ondragenter , ondragleave , ondragover , ondrop ,
onfilterchange , onfocus , onhelp , onkeydown ,
onkeypress , onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onresize , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children ,


filters

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthfiltertext-indentvisibilityfont-styleborder-left-
colormargin-lefttext-autospaceleftfont-
variantbackgrounddirectionborder-bottom-
colorpositionbackground-positionclearborder-right-
colorborder-rightword-spacingtoppadding-leftlayout-
grid-modeheightpadding-bottomrightfont-sizeborder-
bottomletter-spacingdisplayfloatfont-familymargin-
rightbehaviortext-transformbackground-repeatborder-
top-stylebackground-imagebottomcliptext-
decorationcolorborder-styleborder-top-widthborder-
topz-indexmargin-bottompage-break-afterfontborder-
left-styleborder-widthmarginunicode-bidibackground-
colorfont-weightline-heightborder-bottom-stylelayout-
gridborder-left-widthborder-leftpadding-topborder-
colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
CAPTION Element | CAPTION Object
Members
Specifies a brief description for a TABLE.

Properties

accessKey , align , canHaveChildren , className ,


clientHeight , clientLeft , clientTop , clientWidth ,
currentStyle , dir , firstChild , id , innerHTML , innerText
, isTextEdit , lang , language , lastChild , nextSibling ,
nodeName , nodeType , nodeValue , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
parentElement , parentNode , parentTextEdit ,
previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID , vAlign

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , time , userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpadding-rightpaddingborder-right-
widthcursorvisibilityfont-styleborder-left-colormargin-
lefttext-autospacefont-
variantbackgrounddirectionborder-bottom-
colorbackground-positionclearborder-right-colorborder-
rightword-spacingpadding-leftlayout-grid-modepadding-
bottomfont-sizeborder-bottomletter-spacingdisplayfont-
familymargin-rightbehaviortext-transformbackground-
repeatborder-top-stylebackground-imagetext-
decorationcolorborder-styleborder-top-widthborder-
topz-indexmargin-bottomfontborder-left-styleborder-
widthmarginunicode-bidibackground-colorfont-
weightline-heightborder-bottom-stylelayout-gridborder-
left-widthborder-leftpadding-topborder-colorborder-
right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
CENTER Element | CENTER Object
Members
Centers subsequent text and images.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modepadding-bottomrightfont-
sizeborder-bottomoverflowletter-
spacingdisplayfloatfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
CITE Element | CITE Object Members
Indicates a citation by rendering text in italic.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagebottomvisibilityfont-
stylecliptext-autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
clientInformation Object Members
Contains information about the Web browser.

Properties

appCodeName , appMinorVersion , appName ,


appVersion , browserLanguage , cookieEnabled ,
cpuClass , onLine , platform , systemLanguage ,
userAgent , userLanguage , userProfile

Methods

javaEnabled , taintEnabled

Collections

plugins

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
USEMAP Attribute | useMap... userLanguage Pr
Web Workshop | DHTML, HTML & CSS
userAgent Property
Retrieves a string equivalent to the HTTP user-agent request header.

Syntax

HTML N/A
Scripting [ sUserAgent = ] navigator.userAgent

Possible Values

sUserAgent String that specifies a valid HTTP user agent.

The property is read-only with a browser-specific default value.

Remarks

The HTTP user-agent request header contains information about compatibility, the
browser, and the platform name. For more information about the browser, see the
appName property. For more information about the platform, see the appVersion
property.

The userAgent property returns a different value depending on the browser and
platform versions. For example, Microsoft® Internet Explorer 4.01 returns the
following string for Microsoft ® Windows® 95.

Mozilla/4.0 (compatible; MSIE 4.01; Windows 95)

Example

This example uses the userAgent property to specify a required platform before
additional script is executed. For example, if Windows 95 is a requirement for the
document, you can use a variable to determine whether the user is running the
necessary operating system. The "bIs95" variable is set to true if Windows 95 is found
in the userAgent value and the additional script is processed.

<SCRIPT>
var bIs95=false;
window.onload=fnInit;
function fnInit(){
if(navigator.userAgent.indexOf("Windows 95")>-1){
bIs95=true;
}
if(bIs95==true){
// Process additional script.
}
}
</SCRIPT>
Applies To

clientInformation, navigator

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
clipboardData Object Members
Provides access to predefined clipboard formats for use in
editing operations.

Methods

clearData , getData , setData

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
CODE Element | CODE Object Members
Specifies a code sample.

Properties

canHaveChildren , className , clientHeight , clientLeft ,


clientTop , clientWidth , currentStyle , dir , firstChild , id
, innerHTML , innerText , isTextEdit , lang , language ,
lastChild , nextSibling , nodeName , nodeType ,
nodeValue , offsetHeight , offsetLeft , offsetParent ,
offsetTop , offsetWidth , outerHTML , outerText ,
parentElement , parentNode , parentTextEdit ,
previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tagName ,
tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onclick ,
oncontextmenu , oncopy , oncut , ondblclick , ondrag ,
ondragend , ondragenter , ondragleave , ondragover ,
ondragstart , ondrop , onhelp , onkeydown , onkeypress
, onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onresize , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagebottomvisibilityfont-
stylecliptext-autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
COL Element | COL Object Members
Specifies column-based defaults for the table properties.

Properties

align , canHaveChildren , className , clientHeight ,


clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , isTextEdit , lang , lastChild , nextSibling ,
nodeName , nodeType , nodeValue , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
parentElement , parentNode , parentTextEdit ,
previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , span , style ,
tagName , tagUrn , uniqueID , vAlign , width

Methods

addBehavior , appendChild , applyElement , attachEvent


, clearAttributes , cloneNode , componentFromPoint ,
contains , detachEvent , getAdjacentText , getAttribute ,
getBoundingClientRect , getClientRects ,
getElementsByTagName , getExpression ,
hasChildNodes , insertAdjacentElement , insertBefore ,
mergeAttributes , removeAttribute , removeBehavior ,
removeChild , removeExpression , removeNode ,
replaceAdjacentText , replaceChild , replaceNode ,
scrollIntoView , setAttribute , setExpression , swapNode

Events

onreadystatechange

Collections
all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage

Styles

widthfont-sizepadding-rightletter-
spacingdisplaypaddingfont-familycursorbehaviortext-
transformbackground-repeatbackground-imagevertical-
alignvisibilityfont-styletext-autospacefont-varianttext-
decorationbackgroundcolordirectionz-indexbackground-
positionclearfontunicode-bidibackground-colorfont-
weightword-spacingline-heightpadding-leftlayout-
gridlayout-grid-modepadding-toppadding-bottom

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
COLGROUP Element | COLGROUP Object
Members
Contains a group of columns.

Properties

align , canHaveChildren , className , clientHeight ,


clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , isTextEdit , lang , lastChild , nextSibling ,
nodeName , nodeType , nodeValue , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
parentElement , parentNode , parentTextEdit ,
previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , span , style ,
tagName , tagUrn , title , uniqueID , vAlign , width

Methods

addBehavior , appendChild , applyElement , attachEvent


, clearAttributes , cloneNode , componentFromPoint ,
contains , detachEvent , getAdjacentText , getAttribute ,
getBoundingClientRect , getClientRects ,
getElementsByTagName , getExpression ,
hasChildNodes , insertAdjacentElement , insertBefore ,
mergeAttributes , removeAttribute , removeBehavior ,
removeChild , removeExpression , removeNode ,
replaceAdjacentText , replaceChild , replaceNode ,
scrollIntoView , setAttribute , setExpression , swapNode

Events

onreadystatechange
Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage

Styles

widthfont-sizepadding-rightletter-
spacingdisplaypaddingfont-familycursorbehaviortext-
transformbackground-repeatbackground-
imagevisibilityfont-styletext-autospacefont-varianttext-
decorationbackgroundcolordirectionz-indexbackground-
positionclearfontunicode-bidibackground-colorfont-
weightword-spacingline-heightpadding-leftlayout-
gridlayout-grid-modepadding-toppadding-bottom

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
childNodes Collection controlRange Collection
Web Workshop | DHTML, HTML & CSS
children Collection
Retrieves a collection of elements that are direct descendants of the object.

Syntax

[ collChildren = ] object.children
[ oObject = ] object.children(vIndex [, iSubIndex])

Possible Values

collChildren Array containing the direct descendants of an object.


oObject Reference to an individual item in the array of elements contained by the object.
vIndex Required. Integer or string that specifies the element or collection to retrieve. If this parameter is an integer, the method returns the
element in the collection at the given position, where the first element has value 0, the second has 1, and so on. If this parameter is a
string and there is more than one element with the name or id property equal to the string, the method returns a collection of
matching elements.
iSubIndex Optional. Position of an element to retrieve. This parameter is used when vIndex is a string. The method uses the string to construct a
collection of all elements that have a name or id property equal to the string, and then retrieves from this collection the element at
the position specified by iSubIndex.

Members

Remarks

Similar to the objects contained in the all collection, the objects contained in the
children collection are undefined if the child elements are overlapping tags.

The children collection can contain HTML elements.

Example

This example shows how to determine the collections for two DIV elements, divONE
and divTWO. The children collection for divONE includes IMG, DIV, and BUTTON. The
children collection for divTWO includes P.

<DIV id=divONE>
<IMG src=mygif.gif>
<DIV id=divTWO>
<P>Some text in a paragraph
</DIV>
<BUTTON> The label for the button </BUTTON>
</DIV>

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, COL,
COLGROUP, custom, DD, DEL, DFN, DIR, DIV, DL, document, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn, HR, HTML, I,
IFRAME, IMG, INS, KBD, LABEL, LEGEND, LI, LINK, LISTING, MAP, MARQUEE, MENU, NEXTID, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, S,
SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, THEAD, TITLE, TR, TT, U, UL, VAR,
XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
COMMENT Element | COMMENT Object
Members
Indicates a comment that is not displayed.

Properties

canHaveChildren , currentStyle , firstChild , id ,


isTextEdit , lang , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetParent , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , sourceIndex , style ,
tagName , tagUrn , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, clearAttributes , cloneNode , componentFromPoint ,
detachEvent , getAdjacentText , getAttribute ,
getBoundingClientRect , getClientRects , hasChildNodes
, insertAdjacentElement , insertAdjacentHTML ,
insertAdjacentText , insertBefore , mergeAttributes ,
removeAttribute , removeBehavior , removeChild ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , swapNode

Events

onpropertychange , onreadystatechange

Collections

attributes , behaviorUrns , childNodes


Behaviors

clientCaps , download , homePage

Styles

widthbehaviortext-autospace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
HTML Element | HTML Objec... I Element | I Ob
Web Workshop | DHTML, HTML & CSS
HTML Comment Element
Prevents any enclosed text or HTML source code from being parsed and displayed in the
browser window.

Remarks

Comments can contain other HTML elements. Comments do not nest.

Start and end tags are required.

Example

This example uses HTML COMMENT tags, "<!-- -->", to insert a comment in an HTML
document.

<!-- This text will not appear in the browser window. -->

See Also

COMMENT

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
AddFavorite Method addReadRequest Method
Web Workshop | DHTML, HTML & CSS
addImport Method
Adds a style sheet to the imports collection for the given style sheet.

Syntax

iIndex = stylesheet.addImport(sURL [, iIndex])

Parameters

sURL Required. String that specifies the location of the source file for the style sheet.
iIndex Optional. Integer that specifies the requested position for the style sheet in the collection. If this value is not given, the style sheet is added
to the end of the collection.

Return Value

Integer. Returns a zero-based index value that specifies the position of the imported
style sheet in the imports collection.

Applies To

styleSheet

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
currentStyle Object Members
Represents the cascaded format and style of the object as
specified by global style sheets, inline styles, and HTML
attributes.

Properties

backgroundAttachment , backgroundColor ,
backgroundImage , backgroundPositionX ,
backgroundPositionY , backgroundRepeat ,
borderBottomColor , borderBottomStyle ,
borderBottomWidth , borderColor , borderLeftColor ,
borderLeftStyle , borderLeftWidth , borderRightColor ,
borderRightStyle , borderRightWidth , borderStyle ,
borderTopColor , borderTopStyle , borderTopWidth ,
borderWidth , bottom , clear , clipBottom , clipLeft ,
clipRight , clipTop , color , cursor , direction , fontFamily
, fontSize , fontStyle , fontVariant , fontWeight , height ,
layoutGridChar , layoutGridCharSpacing , layoutGridLine
, layoutGridMode , layoutGridType , left , letterSpacing ,
lineHeight , listStyleImage , listStylePosition ,
listStyleType , margin , marginBottom , marginLeft ,
marginRight , marginTop , overflow , overflowX ,
overflowY , pageBreakAfter , pageBreakBefore , right ,
styleFloat , tableLayout , textAlign , textDecoration ,
textIndent , textTransform , top , unicodeBidi ,
verticalAlign , visibility , width , zIndex

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
XMLDocument Property y Property DHTML Pr
Web Workshop | DHTML, HTML & CSS
XMLNS Attribute
Declares a namespace for custom tags in an HTML document.

Syntax

HTML <HTML XMLNS:sNamespace ... >


Script N/A

Possible Values

sNamespace String that specifies the namespace used as a prefix to custom tags, or the following value:
urn Uniform Resource Name (URN) that uniquely identifies the namespace.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The syntax for XMLNS is based on the W3C xml namespace spec . Although the
I
W3C draft allows you to declare namespaces on all tags, Internet Explorer supports
namespace declaration only on the HTML tag.

You can declare multiple namespaces on the HTML tag, as the syntax below shows:

<HTML XMLNS:Prefix1 XMLNS:Prefix2="www.microsoft.com">

Example

This example shows how to declare a namespace when one of the default behaviors in
Internet Explorer, clientCaps, is used as a custom tag in an HTML document. Note how
you must add the declared namespace (in this case, MSIE) to the custom tag when it
is defined.

This example also shows how the clientCaps behavior can be used to install the
Internet Explorer Data Binding component, if the component does not already exist in
the user's system.

Applies To

HTML

See Also

xml namespaces spec


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
@import Rule ACCESSKEY Attribute | acc... D
Web Workshop | DHTML, HTML & CSS
@media Rule
Sets the media types for a set of styleSheet rules.

Syntax

HTML @media sMediaType { sRules }


Scripting N/A

Possible Values

sMediaType screen Output is intended for computer screens.


print Output is intended for printed material and for documents on screen viewed in Print Preview mode.
all Applies to all devices.
sRules One or more rules in a styleSheet object.

The rule has no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Example

This example shows how to implement the @media rule.

// For computer screens, the font size is 12pt.


@media screen {
BODY {font-size: 12pt;}
}
// When printed, the font size is 8pt.
@media print {
BODY {font-size: 8pt;}
}

Applies To

STYLE

See Also

media

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
custom Element | custom Object Members
Represents a user-defined element.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
document , id , innerHTML , innerText , isTextEdit , lang
, language , offsetHeight , offsetLeft , offsetParent ,
offsetTop , offsetWidth , outerHTML , outerText ,
parentElement , parentTextEdit , readyState ,
recordNumber , runtimeStyle , scopeName ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , style , tabIndex , tagName , tagUrn , title

Methods

addBehavior , applyElement , attachEvent , blur ,


clearAttributes , click , componentFromPoint , contains ,
detachEvent , doScroll , focus , getAdjacentText ,
getAttribute , getBoundingClientRect , getClientRects ,
getElementsByTagName , getExpression ,
insertAdjacentHTML , insertAdjacentText ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeExpression ,
replaceAdjacentText , scrollIntoView , setAttribute ,
setCapture , setExpression

Events

onafterupdate , onbeforecopy , onbeforecut ,


onbeforeeditfocus , onbeforepaste , onbeforeupdate ,
onblur , onclick , oncontextmenu , oncopy , oncut ,
ondblclick , ondrag , ondragend , ondragenter ,
ondragleave , ondragover , ondragstart , ondrop ,
onerrorupdate , onfilterchange , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onscroll , onselectstart

Collections

all , behaviorUrns , children , filters

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpadding-rightpaddingborder-right-
widthcursorvertical-alignfiltervisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xfont-
variantoverflow-ybackgrounddirectionborder-bottom-
colorpositionbackground-positionclearborder-right-
colorborder-rightword-spacingtoppadding-leftlayout-
grid-modeheightpadding-bottomfont-sizeborder-
bottomoverflowletter-spacingdisplayfloatfont-
familymargin-rightbehaviortext-transformbackground-
repeatborder-top-stylebackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottomfontborder-
left-styleborder-widthmarginunicode-bidibackground-
colorfont-weightline-heightborder-bottom-stylelayout-
gridborder-left-widthborder-leftpadding-topborder-
colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
setCapture Method setEndPoint Method DHTM
Web Workshop | DHTML, HTML & CSS
setData Method
Assigns data in a specified format to the dataTransfer or clipboardData object.

Syntax

bSuccess = object.setData(sDataFormat, sData)

Parameters

sDataFormat Required. String that specifies the format of the data to be transferred, using one of the following values:
Text Transfers data formatted as text.
URL Transfers data formatted as a URL.
sData Required. String that specifies the data supplied by the source object. This information can be descriptive text, a source path to an
image, or a URL for an anchor. When you pass URL as the sDataFormat parameter, you must use sData to provide the location of the
object being transferred.

Return Value

Boolean. Returns true if the data was successfully added, or false otherwise.

Remarks

The value of the sDataFormat parameter is not case-sensitive.

Example

This example uses the setData and getData methods with the dataTransfer object to
create a shortcut to an image.

Applies To

clipboardData, dataTransfer

See Also

data transfer overview , clearData, getData


I

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
getClientRects Method getElementById Method
Web Workshop | DHTML, HTML & CSS
getData Method
Retrieves the data in the specified format from the clipboard through the dataTransfer or
clipboardData objects.

Syntax

sRetrieveData = object.getData(sDataFormat)

Parameters

sDataFormat Required. String that specifies one of the following data format values:
Text Retrieves data formatted as text.
URL Retrieves data formatted as a URL.

Return Value

String. Returns the data in the format retrieved from clipboard through the
dataTransfer or clipboardData object. Depending on the information contained in
setData, this variable can retrieve a path to an image, text, or an anchor URL.

Remarks

The getData method enforces cross-frame security and allows data transfers within
the same domain only. To the user this means that dragging a selection between
different security protocols, such as HTTP and HTTPS, will fail. In addition, dragging a
selection between two instances of the browser with different security levels, where
the first instance is set to medium and the second is set to high, will fail. Finally,
dragging a selection into the browser from another drag-enabled application, such as
Microsoft® Word, also will fail.

To use the getData method to retrieve data from the clipboard within the oncopy or
oncut event, specify window.event.returnValue=false within the event handler
script.

Example

The following examples use the setData and getData methods of the dataTransfer
object to drop text in a new location and create a desktop shortcut.

Applies To

clipboardData, dataTransfer

See Also

dhtml data transfer overview , clearData, setData


I
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
dataTransfer Object Members
Provides access to predefined clipboard formats for use in
drag-and-drop operations.

Properties

dropEffect , effectAllowed

Methods

clearData , getData , setData

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
DD Element | DD Object Members
Indicates the definition in a definition list. The definition is
usually indented in the definition list.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , noWrap , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
outerHTML , outerText , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
recordNumber , runtimeStyle , scopeName ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , style , tabIndex , tagName , tagUrn , title
, uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modepadding-bottomrightfont-
sizeborder-bottomoverflowletter-
spacingdisplayfloatfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
DEL Element | DEL Object Members
Indicates text that has been deleted from the document.

Properties

accessKey , canHaveChildren , className , currentStyle


, dir , firstChild , id , innerHTML , innerText , isTextEdit ,
lang , language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , sourceIndex , style ,
tabIndex , tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , cloneNode ,
componentFromPoint , detachEvent , focus ,
getAdjacentText , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement , insertBefore ,
mergeAttributes , removeBehavior , removeChild ,
removeExpression , removeNode , replaceAdjacentText ,
replaceChild , replaceNode , setExpression , swapNode

Events

onblur , ondrag , ondragend , ondragenter ,


ondragleave , ondragover , ondragstart , ondrop ,
onfocus , onkeydown , onkeypress , onkeyup ,
onreadystatechange , onselectstart
Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthdirectionoverflowpadding-
rightdisplaypaddingunicode-bidibehaviorpadding-
leftlayout-gridlayout-grid-modetext-autospacepadding-
topoverflow-xpadding-bottomoverflow-y

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
DFN Element | DFN Object Members
Indicates the defining instance of a term.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagebottomtext-indentvisibilityfont-
stylecliptext-autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
DIR Element | DIR Object Members
Denotes a directory list.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modepadding-bottomrightfont-
sizeborder-bottomoverflowletter-
spacingdisplayfloatfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
DIV Element | DIV Object Members
Specifies a container that renders HTML.

Properties

accessKey , align , canHaveChildren , className ,


clientHeight , clientLeft , clientTop , clientWidth ,
currentStyle , dataFld , dataFormatAs , dataSrc , dir ,
firstChild , id , innerHTML , isTextEdit , lang , language ,
lastChild , nextSibling , nodeName , nodeType ,
nodeValue , noWrap , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , doScroll
, getAdjacentText , getAttribute , getBoundingClientRect
, getClientRects , getElementsByTagName ,
getExpression , hasChildNodes , insertAdjacentElement
, insertAdjacentHTML , insertAdjacentText , insertBefore
, mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforeeditfocus ,
onbeforepaste , onblur , onclick , oncontextmenu ,
oncopy , oncut , ondblclick , ondrag , ondragend ,
ondragenter , ondragleave , ondragover , ondragstart ,
ondrop , onfilterchange , onfocus , onhelp , onkeydown
, onkeypress , onkeyup , onlosecapture , onmousedown
, onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onresize , onscroll , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children ,


filters

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursorfiltertext-indentvisibilityfont-
styleborder-left-colormargin-lefttext-
autospaceleftoverflow-xlayout-grid-linefont-
variantoverflow-yline-breakbackgroundtext-
aligndirectionborder-bottom-colortext-
justifypositionbackground-positionclearborder-right-
colorborder-rightword-spacingtoppadding-leftlayout-
grid-modeheightpadding-bottomrightfont-sizeborder-
bottomoverflowletter-spacingdisplayfloatfont-
familymargin-rightbehaviorword-breaktext-
transformbackground-repeatborder-top-stylelayout-
grid-charbackground-imagebottomcliptext-
decorationcolorborder-styleborder-top-widthborder-
topz-indexmargin-bottompage-break-afterfontborder-
left-styleborder-widthmarginunicode-bidibackground-
colorfont-weightline-heightborder-bottom-stylelayout-
gridlayout-grid-typelayout-grid-char-spacingborder-left-
widthborder-leftpadding-topborder-colorborder-right-
styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
DL Element | DL Object Members
Denotes a definition list.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , compact ,
currentStyle , dir , firstChild , id , innerHTML , isTextEdit
, lang , language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onlosecapture , onmousedown , onmousemove ,
onmouseout , onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modepadding-bottomrightfont-
sizeborder-bottomoverflowletter-
spacingdisplayfloatfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
nextPage Method open Method DHTML Metho
Web Workshop | DHTML, HTML & CSS
open Method
Opens a new window and loads the document specified by a given URL, or opens a blank
document if a URL is not provided.

Syntax

oNewWindow=window.open([sURL] [, sName] [, sFeatures] [, bReplace])

Parameters

sURL Optional. String that specifies the URL of the document to display. If no URL is specified, a new window with about:blank is displayed.
sName Optional. String that specifies the name of the window. This name is used as the value for the TARGET attribute on a FORM or an A
element.
In Internet Explorer 5 and later, specifying the value _search opens sURL in the browser's search pane.

sFeatures Optional. String that specifies the window ornaments to display. The following features are supported:
channelmode = { yes | no | 1 | 0 } Specifies whether to display the window in theater mode and show
the channel band. The default is no.
directories = { yes | no | 1 | 0 } Specifies whether to add directory buttons. The default is yes.
fullscreen = { yes | no | 1 | 0 } Specifies whether to display the browser in a full-screen or normal
window. The default is no, which displays the browser in a normal
window.
Use full-screen mode carefully. Because this mode hides the
browser's title bar and menus, you should always provide a button or
other visual clue to help the user close the window. ALT+F4 also
closes the new window.

height = number Specifies the height of the window, in pixels. The minimum value is
100.
left = number Specifies the left position, in pixels. This value is relative to the
upper-left corner of the screen.
location = { yes | no | 1 | 0 } Specifies whether to display the input field for entering URLs directly
into the browser. The default is yes.
menubar = { yes | no | 1 | 0 } Specifies whether to display the menu bar. The default is yes.
resizable = { yes | no | 1 | 0 } Specifies whether to display resize handles at the corners of the
window. The default is yes.
scrollbars = { yes | no | 1 | 0 } Specifies whether to display horizontal and vertical scroll bars. The
default is yes.
status = { yes | no | 1 | 0 } Specifies whether to add a status bar at the bottom of the window.
The default is yes.
titlebar = { yes | no | 1 | 0 } Specifies whether to display a title bar for the window. This
parameter is ignored unless the caller is an html applicationIn or a
trusted dialog box. The default is yes.
toolbar = { yes | no | 1 | 0 } Specifies whether to display the browser toolbar, making buttons
such as Back, Forward, and Stop available. The default is yes.
top = number Specifies the top position, in pixels. This value is relative to the
upper-left corner of the screen.
width = number Sets the width of the window, in pixels. The minimum value is 100.
bReplace Optional. Boolean that specifies whether the URL that is loaded into the new page should create a new entry in the window's browsing
history or replace the current entry in the browsing history. If set to true, no new history entry is created.

Return Value

Returns a reference to the new window object. Use this reference to script properties
and methods on the new window.

Remarks
By default, the open method creates a window that has a default width and height and
the standard menu, toolbar, and other features of Microsoft® Internet Explorer. You
can alter this set of features by using the sFeatures parameter. This parameter is a
string consisting of one or more feature settings. When one feature is specified, any
additional features that are not specified are disabled. If no features are specified, the
window features maintain their default values. In addition to enabling a feature with
the specified possible value, simply listing the feature name also enables that feature
for the new window.

Internet Explorer 5 allows further control over windows through the implementation of
title in the sFeatures parameter of the open method. Turn off the title bar by
opening the window from a trusted application, such as Microsoft® Visual Basic® or an
HTML Application (HTA). These applications are considered trusted, because each uses
Internet Explorer interfaces instead of the browser.

Windows CE

In Microsoft® Windows® CE, the document object is not available through scripting for
a window opened using the open method.

Example

This example uses the open method to create a new window that contains
Sample.htm. The new window is 200 pixels by 400 pixels and has a status bar, but it
does not have a toolbar, menu bar, or address field.

window.open("Sample.htm",null,

"height=200,width=400,status=yes,toolbar=no,menubar=no,location=
no");

Applies To

window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
document Object Members
Represents the HTML document in a given browser window.

Properties

activeElement , aLinkColor , bgColor , cookie ,


defaultCharset , designMode , documentElement ,
domain , expando , fgColor , fileCreatedDate ,
fileModifiedDate , fileSize , lastModified , linkColor ,
location , parentWindow , protocol , readyState ,
referrer , selection , uniqueID , URL , vlinkColor

Methods

attachEvent , clear , clearAttributes , close ,


createElement , createStyleSheet , createTextNode ,
detachEvent , elementFromPoint , execCommand ,
getElementById , getElementsByName ,
getElementsByTagName , mergeAttributes , open ,
queryCommandEnabled , queryCommandIndeterm ,
queryCommandState , queryCommandSupported ,
queryCommandValue , recalc , releaseCapture , write ,
writeln

Events

onbeforecut , onbeforeeditfocus , onbeforepaste ,


onclick , oncontextmenu , oncut , ondblclick , ondrag ,
ondragend , ondragenter , ondragleave , ondragover ,
ondragstart , ondrop , onhelp , onkeydown , onkeypress
, onkeyup , onmousedown , onmousemove ,
onmouseout , onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onstop
Collections

all , anchors , applets , childNodes , children , embeds ,


forms , frames , images , links , scripts , styleSheets

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
DT Element | DT Object Members
Indicates a definition term within a definition list.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , isTextEdit , lang , language ,
lastChild , nextSibling , nodeName , nodeType ,
nodeValue , noWrap , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modepadding-bottomfont-sizeborder-
bottomoverflowletter-spacingdisplayfloatfont-
familymargin-rightbehaviorword-breaktext-
transformbackground-repeatborder-top-stylelayout-
grid-charbackground-imagecliptext-
decorationcolorborder-styleborder-top-widthborder-
topz-indexmargin-bottompage-break-afterfontborder-
left-styleborder-widthmarginunicode-bidibackground-
colorfont-weightline-heightborder-bottom-stylelayout-
gridlayout-grid-typelayout-grid-char-spacingborder-left-
widthborder-leftpadding-topborder-colorborder-right-
styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
EM Element | EM Object Members
Emphasizes text, usually by rendering it in italic.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagevisibilityfont-stylecliptext-
autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottom

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
EMBED Element | EMBED Object Members
Allows documents of any type to be embedded.

Properties

accessKey , align , className , clientHeight , clientLeft ,


clientTop , clientWidth , currentStyle , dir , firstChild ,
height , hidden , id , isTextEdit , lang , language ,
lastChild , nextSibling , nodeName , nodeType ,
nodeValue , offsetHeight , offsetLeft , offsetParent ,
offsetTop , offsetWidth , outerHTML , outerText , palette
, parentElement , parentNode , parentTextEdit ,
pluginspage , previousSibling , readyState ,
recordNumber , runtimeStyle , scopeName ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , src , style , tabIndex , tagName , tagUrn ,
title , uniqueID , units , width

Methods

addBehavior , applyElement , attachEvent , blur ,


clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName ,
hasChildNodes , insertAdjacentElement ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeExpression ,
replaceAdjacentText , scrollIntoView , setAttribute ,
setCapture , setExpression , swapNode

Events
onbeforecut , onbeforepaste , onblur , onclick ,
oncontextmenu , oncut , ondblclick , onfocus , onhelp ,
onload , onlosecapture , onmousedown , onmousemove
, onmouseout , onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onscroll

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage

Styles

border-top-colorwidthmargin-topborder-bottom-
widthborder-bottomoverflowpadding-
rightfloatdisplaypaddingmargin-rightborder-right-
widthcursorbehaviorborder-top-stylevisibilityclipborder-
left-colormargin-lefttext-autospaceleftoverflow-
xoverflow-yborder-styleborder-topborder-top-
widthdirectionborder-bottom-colormargin-
bottompositionclearborder-left-styleborder-right-
colorborder-rightmarginborder-widthunicode-
biditoppadding-leftborder-bottom-stylelayout-
gridborder-left-widthborder-leftheightlayout-grid-
modepadding-toppadding-bottomborder-colorborder-
right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
FRAMESPACING Attribute | ... hash Property
Web Workshop | DHTML, HTML & CSS
fromElement Property
Retrieves the object the mouse pointer is exiting during the onmouseover and onmouseout
events.

Syntax

HTML N/A
Scripting [ oObject = ] event.fromElement

Possible Values

oObject Object that specifies the previous location of the mouse pointer.

The property is read-only with no default value.

Example

In this example, the alert returns "mouse arrived" when the mouse pointer moves over
the button.

<SCRIPT>
function testMouse(oObject) {
if(!oObject.contains(event.fromElement)) {
alert("mouse arrived");
}
}
</SCRIPT>
:
<BUTTON ID=oButton onmouseover="testMouse(this)">Mouse Over
This.</BUTTON>

This feature requires Internet Explorer 5 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

HTML N/A
Scripting event

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
TITLE Attribute | title P... top Attribute | top Pro
Web Workshop | DHTML, HTML & CSS
toElement Property
Retrieves a reference to the object to which the user is moving the mouse pointer.

Syntax

HTML N/A
Scripting [ oObject = ] event.toElement

Possible Values

oObject Object that specifies the object being moved to by the mouse.

The property is read-only with no default value.

Example

This example uses the toElement property to display the tagName of the object to
which the user moves the mouse pointer.

<SCRIPT>
function fnGetTo(){
spanTo.innerHTML=window.event.toElement.tagName;
}

</SCRIPT>
:
<SPAN onmouseout="fnGetTo()">
<P>Mouse Over This</P>
<P>toElement: <SPAN ID="spanTo"></SPAN></P>
</SPAN>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

HTML N/A
Scripting event

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onmouseout Event onmouseup Event DHTML
Web Workshop | DHTML, HTML & CSS
onmouseover Event
Fires when the user moves the mouse pointer into the object.

Syntax

Inline HTML <ELEMENT onmouseover = "handler" ... > All platforms


Event property object.onmouseover = handler JScript (compatible with ECMA 262 language specification) only
Named script <SCRIPT FOR = object EVENT = onmouseover> Internet Explorer only

Remarks

Bubbles Yes
Cancels Yes
To invoke Move the mouse pointer into an object.
Default action Initiates any action associated with this event.

The event occurs when the user moves the mouse pointer into the object, and it does
not repeat unless the user moves the mouse pointer out of the object and then back
into it.

Event Object Properties

Although event handlers in the DHTML Object Model do not receive parameters
directly, the handler can query the event object for data.

Example

This example uses the onmouseover event to apply a new style to an object.

<DIV>
<P onmouseover="this.style.color='red'"
onmouseout="this.style.color='black'">
Move the mouse pointer over this text, then move it elsewhere in
the
document. Move the mouse pointer over this text, then move it
elsewhere in the document.
</DIV>

This example shows how to change the value of a text area in response to mouse
events.

<DIV>
<P>Move the mouse pointer into the text area to fire the
onmouseover event. Move it out to clear the text.
<TEXTAREA NAME=txtMouseTrack
onmouseover="this.value='onmouseover fired'"
onmouseout="this.value=''">
</TEXTAREA>
</DIV>
This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ADDRESS, APPLET, AREA, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, custom, DD, DFN, DIR, DIV, DL,
document, DT, EM, EMBED, FIELDSET, FONT, FORM, Hn, HR, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT
type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, KBD, LABEL, LEGEND, LI,
LISTING, MAP, MARQUEE, MENU, NEXTID, NOBR, OL, P, PLAINTEXT, PRE, RT, RUBY, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP,
TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

onmousedown, onmousemove, onmouseout, onmouseup

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onmousemove Event onmouseover Event DH
Web Workshop | DHTML, HTML & CSS
onmouseout Event
Fires when the user moves the mouse pointer outside the boundaries of the object.

Syntax

Inline HTML <ELEMENT onmouseout = "handler" ... > All platforms


Event property object.onmouseout = handler JScript (compatible with ECMA 262 language specification) only
Named script <SCRIPT FOR = object EVENT = onmouseout> Internet Explorer only

Remarks

Bubbles Yes
Cancels No
To invoke Move the mouse pointer out of an object.
Default action Initiates any action associated with this event.

When the user moves the mouse over an object, one onmouseover event occurs,
followed by one or more onmousemove events as the user moves the mouse pointer
within the object. One onmouseout event occurs when the user moves the mouse
pointer out of the object.

Event Object Properties

Although event handlers in the DHTML Object Model do not receive parameters
directly, the handler can query the event object for data.

Example

The following examples use the mouseout event to create interactive effects.

Applies To

A, ADDRESS, APPLET, AREA, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, custom, DD, DFN, DIR, DIV, DL,
document, DT, EM, EMBED, FIELDSET, FONT, FORM, Hn, HR, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT
type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, KBD, LABEL, LEGEND, LI,
LISTING, MAP, MARQUEE, MENU, OL, P, PLAINTEXT, PRE, RT, RUBY, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY,
TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

onmousedown, onmousemove, onmouseover, onmouseup

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
event Object Members
Represents the state of an event, such as the element in
which the event occurred, the state of the keyboard keys,
the location of the mouse, and the state of the mouse
buttons.

Properties

altKey , button , cancelBubble , clientX , clientY , ctrlKey


, dataFld , dataTransfer , fromElement , keyCode ,
offsetX , offsetY , propertyName , qualifier , reason ,
recordset , repeat , returnValue , screenX , screenY ,
shiftKey , srcElement , srcFilter , srcUrn , toElement ,
type , x , y

Collections

bookmarks , boundElements

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
external Object Members
Allows access to an additional object model provided by
host applications of the Microsoft® Internet Explorer
browser components.

Properties

menuArguments

Methods

AddChannel , AddDesktopComponent , AddFavorite ,


AutoCompleteSaveForm , AutoScan ,
ImportExportFavorites , IsSubscribed , NavigateAndFind
, ShowBrowserUI

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
FIELDSET Element | FIELDSET Object
Members
Draws a box around the text and other elements that the
field set contains.

Properties

accessKey , align , canHaveChildren , className ,


clientHeight , clientLeft , clientTop , clientWidth ,
currentStyle , dir , firstChild , id , innerHTML , innerText
, isTextEdit , lang , language , lastChild , nextSibling ,
nodeName , nodeType , nodeValue , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
outerHTML , outerText , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
recordNumber , runtimeStyle , scopeName ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , style , tabIndex , tagName , tagUrn , title
, uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events

onbeforecopy , onbeforecut , onbeforeeditfocus ,


onbeforepaste , onblur , onclick , oncontextmenu ,
oncopy , oncut , ondblclick , ondrag , ondragend ,
ondragenter , ondragleave , ondragover , ondragstart ,
ondrop , onfilterchange , onfocus , onhelp , onkeydown
, onkeypress , onkeyup , onlosecapture , onmousedown
, onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onresize , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children ,


filters

Behaviors

clientCaps , download , homePage , time

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modeheightpadding-bottomrightfont-
sizeborder-bottomoverflowletter-
spacingdisplayfloatfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
FONT Element | FONT Object Members
Specifies a new font, size, and color to be used for
rendering the enclosed text.

Properties

accessKey , canHaveChildren , className , color ,


currentStyle , dir , face , firstChild , id , innerHTML ,
innerText , isTextEdit , lang , language , lastChild ,
nextSibling , nodeName , nodeType , nodeValue ,
offsetHeight , offsetLeft , offsetParent , offsetTop ,
offsetWidth , outerHTML , outerText , parentElement ,
parentNode , parentTextEdit , previousSibling ,
readyState , recordNumber , runtimeStyle , scopeName
, size , sourceIndex , style , tabIndex , tagName ,
tagUrn , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecut , onbeforepaste , onblur , onclick ,
oncontextmenu , oncut , ondblclick , ondrag ,
ondragend , ondragenter , ondragleave , ondragover ,
ondragstart , ondrop , onfocus , onhelp , onkeydown ,
onkeypress , onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthdirectionoverflowpadding-
rightdisplaypaddingunicode-bidibehaviorpadding-
leftlayout-gridlayout-grid-modetext-autospacepadding-
topoverflow-xpadding-bottomoverflow-y

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
MULTIPLE Attribute | mult... NAME Attribute | n
Web Workshop | DHTML, HTML & CSS
NAME Attribute | name Property
Sets or retrieves the window or frame name.

Syntax

HTML <ELEMENT NAME = sName ... >


Scripting object.name [ = sName ]

Possible Values

sName String that specifies one of the following values:


_blank Link is loaded into a new, unnamed window.
_parent Link is loaded over the parent. If the frame has no parent, this value refers to _self.
_self Page is replaced with the specified link.
_top Link is loaded at the topmost level.
name Arbitrary name used to identify the object.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The name property identifies which frame displays the content of a linked document.

To access a window's name property, use the window keyword.

Example

This example assigns the name property to the window object.

window.name="MyWindow";

This example uses scripting to set the name property of a frame.

parent.frames[0].name="Left";

This example shows how the NAME attribute for a window can be persisted in HTML,
but only when defined in a frame within a frameset.

<FRAMESET>
<FRAME NAME="Left" SRC="blank.htm">
<FRAME NAME="Right" SRC="contents.htm">
</FRAMESET>

This example uses the window's open method to assign the name property.
window.open("file.htm","Frame1");

Applies To

FRAME, IFRAME, window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
HTTP-EQUIV Attribute | ht... ime-mode Attribut
Web Workshop | DHTML, HTML & CSS
ID Attribute | id Property
Retrieves the string identifying the object.

Syntax

HTML <ELEMENT ID = sID ... >


Scripting [ sID = ] object.id

Possible Values

sID Any alphanumeric string that begins with a letter. The underscore (_) can also be used.

In Microsoft® Internet Explorer 5 and later, the property is read/write. The property
has no default value.

Remarks

In versions earlier than Internet Explorer 5, the property is read-only.

The id should be unique throughout the scope of the current document. If a document
contains more than one object with the same identifier, the objects are exposed as a
collection that can be referenced only in ordinal position.

Example

This example sets the ID attribute and then passes it to a function to manipulate the
object that the attribute is attached to.

<SCRIPT>
function checkCols(oObject)
{
var iColumns = oObject.cols;
alert (iColumns);
}
</SCRIPT>
</HEAD>
<BODY>
<TABLE ID=oTable BORDER COLS=3 onclick="checkCols(this)">
<TR><TD>Column 1</TD><TD>Column 2</TD><TD>Column 3</TD></TR>
</TABLE>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BGSOUND, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE,
CODE, COL, COLGROUP, COMMENT, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn,
HR, HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, ISINDEX, KBD, LABEL, LEGEND, LI, LINK,
LISTING, MAP, MARQUEE, MENU, NEXTID, NOBR, NOFRAMES, NOSCRIPT, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP,
SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, styleSheet, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL,
VAR, WBR, XML, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
controlRange Collection embeds Collection DH
Web Workshop | DHTML, HTML & CSS
elements Collection
Retrieves a collection, in source order, of all objects in a given form.

Syntax

[collElements = ]form.elements
[oObject= ]form.elements(vIndex [,iSubIndex])

Possible Values

collElements Array of INPUT, SELECT, and TEXTAREA objects.


oObject Reference to an individual item in the array of elements contained by the object.
vIndex Required. Integer or string that specifies the element or collection to retrieve. If this parameter is an integer, the method returns the
element in the collection at the given position, where the first element has value 0, the second has 1, and so on. If this parameter is a
string and there is more than one element with the name or id property equal to the string, the method returns a collection of
matching elements.
iSubIndex Optional. Position of an element to retrieve. This parameter is used when vIndex is a string. The method uses the string to construct a
collection of all elements that have a name or id property equal to the string, and then retrieves from this collection the element at
the position specified by iSubIndex.

Members

Remarks

This collection can contain any combination of the INPUT, SELECT, and TEXTAREA
objects.

Applies To

FORM

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onstop Event onunload Event DHTML Events
Web Workshop | DHTML, HTML & CSS
onsubmit Event
Fires when a form is about to be submitted.

Syntax

Inline HTML <FORM onsubmit = "handler" ... > All platforms


Event property form.onsubmit = handler JScript (compatible with ECMA 262 language specification) only
Named script <SCRIPT FOR = form EVENT = onsubmit> Internet Explorer only

Remarks

Bubbles No
Cancels Yes
To invoke Submit a form using the INPUT TYPE=submit, INPUT TYPE=image, or BUTTON TYPE=submit object.
Default action Causes a form to be sent to whatever location is stipulated in the ACTION attribute of the form object.

You can override this event by returning false in the event handler. Use this capability
to validate data on the client side to prevent invalid data from being submitted to the
server. If the event handler is called by the onsubmit attribute of the form object, the
code must explicitly request the return value using the return function, and the event
handler must provide an explicit return value for each possible code path in the event
handler function.

The submit method does not invoke the onsubmit event handler.

Event Object Properties

Although event handlers in the DHTML Object Model do not receive parameters
directly, the handler can query the event object for data.

Example

This example shows how to use onsubmit on a form to request the return value using
the return function.

<BODY>
<FORM NAME="oDoSubmit"
onsubmit="return(myOnSubmitEventHandler());">
</FORM>
</BODY>

Applies To

FORM

See Also

ACTION, METHOD
Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
FORM Element | FORM Object Members
Specifies that the contained controls take part in a form.

Properties

action , autocomplete , canHaveChildren , className ,


clientHeight , clientLeft , clientTop , clientWidth ,
currentStyle , dir , encoding , firstChild , id , innerHTML
, innerText , isTextEdit , lang , language , lastChild ,
method , name , nextSibling , nodeName , nodeType ,
nodeValue , offsetHeight , offsetLeft , offsetParent ,
offsetTop , offsetWidth , outerHTML , outerText ,
parentElement , parentNode , parentTextEdit ,
previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , target , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , reset , scrollIntoView , setAttribute ,
setCapture , setExpression , submit , swapNode , urns

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onreset ,
onresize , onselectstart , onsubmit

Collections

all , attributes , behaviorUrns , childNodes , children ,


elements

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modepadding-bottomrightfont-
sizeborder-bottomoverflowletter-
spacingdisplayfloatfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
ACCESSKEY Attribute | acc... active Pseudo-cla
Web Workshop | DHTML, HTML & CSS
ACTION Attribute | action Property
Sets or retrieves the URL to which the FORM content is to be sent for processing.

Syntax

HTML <FORM ACTION = sURL ... >


Scripting form.action [ = sURL]

Possible Values

sURL String that specifies the URL to be used. If a relative path is specified, the base URL of the document is assumed.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

The way the data is submitted depends on the value of the method and encoding
properties.

Example

This example uses the ACTION attribute to post a form to a specified URL.

<HTML>
<FORM ACTION="http://example.microsoft.com/sample.asp"
METHOD="POST">
Enter your name: <INPUT NAME="FName"><BR>
Favorite Ice Cream Flavor:
<SELECT NAME="Flavor">
<OPTION VALUE="Chocolate">Chocolate
<OPTION VALUE="Strawberry">Strawberry
<OPTION VALUE="Vanilla" SELECTED>Vanilla
</SELECT>
<P><INPUT TYPE=SUBMIT>
</FORM>
</HTML>

This example uses the ACTION attribute to specify a URL for the mailto protocol .
I

<form ACTION="mailto:[email protected]" method=GET>


<input name=subject type=hidden
value="Widget%20Product%20Information%20Request">
Enter your full mailing address<BR>
<TextArea name=body cols=40></textarea>
<input type=submit value="Send Request"
</form>

Applies To

FORM

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
menuArguments Property METHODS Attribute
Web Workshop | DHTML, HTML & CSS
METHOD Attribute | method Property
Sets or retrieves how to send the form data to the server.

Syntax

HTML <FORM METHOD = sMethod ... >


Scripting form.method [ =sMethod ]

Possible Values

sMethod String that specifies one of the following values:


get Append the arguments to the action URL and open it as if it were an anchor.
post Send the data through an HTTP post transaction.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Applies To

FORM

See Also

action

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
FRAME Element | FRAME Object Members
Specifies an individual frame within a FRAMESET element.

Properties

borderColor , className , dataFld , dataSrc , firstChild ,


frameBorder , height , id , isTextEdit , lang , language ,
lastChild , marginHeight , marginWidth , name ,
nextSibling , nodeName , nodeType , nodeValue ,
noResize , offsetHeight , offsetLeft , offsetParent ,
offsetTop , offsetWidth , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
runtimeStyle , scopeName , scrolling , self ,
sourceIndex , src , style , tabIndex , tagName , tagUrn ,
title , uniqueID , width

Methods

addBehavior , applyElement , attachEvent , blur ,


clearAttributes , cloneNode , componentFromPoint ,
contains , detachEvent , focus , getAdjacentText ,
getAttribute , getElementsByTagName , hasChildNodes ,
insertAdjacentElement , mergeAttributes ,
removeAttribute , removeBehavior ,
replaceAdjacentText , setAttribute , swapNode

Events

onblur , onfocus , onresize

Collections

all , attributes , behaviorUrns , childNodes , children


Behaviors

clientCaps , download , homePage

Styles

widthpadding-rightdisplaypaddingbehaviorpadding-
leftlayout-gridlayout-grid-modepadding-toptext-
autospacepadding-bottom

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
FRAMESET Element | FRAMESET Object
Members
Specifies a frameset, which is used to organize multiple
frames and nested framesets.

Properties

border , borderColor , canHaveChildren , className ,


cols , firstChild , frameBorder , frameSpacing , id ,
innerHTML , isTextEdit , lang , language , lastChild ,
nextSibling , nodeName , nodeType , nodeValue ,
outerHTML , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState , rows ,
runtimeStyle , scopeName , sourceIndex , style ,
tabIndex , tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getElementsByTagName
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , removeAttribute , removeBehavior ,
removeChild , removeNode , replaceAdjacentText ,
replaceChild , replaceNode , setAttribute , swapNode

Events

onafterprint , onbeforeprint , onbeforeunload , onblur ,


onfocus , onload , onunload
Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage

Styles

widthbehaviorlayout-gridlayout-grid-mode

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
HEAD Element | HEAD Object Members
Provides an unordered collection of information about the
document.

Properties

canHaveChildren , className , clientHeight , clientLeft ,


clientTop , clientWidth , currentStyle , firstChild , id ,
innerHTML , innerText , isTextEdit , lang , lastChild ,
nextSibling , nodeName , nodeType , nodeValue ,
outerHTML , outerText , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tagName ,
tagUrn , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, clearAttributes , cloneNode , componentFromPoint ,
contains , detachEvent , getAdjacentText , getAttribute ,
getElementsByTagName , hasChildNodes ,
insertAdjacentElement , insertBefore , mergeAttributes ,
removeAttribute , removeBehavior , removeChild ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , setAttribute , swapNode

Events

onreadystatechange

Collections

all , attributes , behaviorUrns , childNodes , children


Behaviors

clientCaps , download , homePage

Styles

widthbehaviorlayout-gridlayout-grid-modetext-
autospace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
autoscan Method blur Method DHTML Method
Web Workshop | DHTML, HTML & CSS
back Method
Loads a URL from the History list.

Syntax

history.back([iDistance])

Parameters

iDistance Optional. Integer that specifies the number of URLs to go back. If no value is provided, the previous URL is loaded.

Return Value

No return value.

Remarks

This method performs the same action as when a user clicks the Back button in the
browser. The back method works the same as history.go(-1). An error does not
occur if the user tries to go beyond the beginning of the history. Instead, the user
remains at the current page.

Applies To

history

See Also

forward, go

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
focus Method getAdjacentText Method DHTML
Web Workshop | DHTML, HTML & CSS
forward Method
Loads the next URL in the History list.

Syntax

history.forward()

Return Value

No return value.

Remarks

This method performs the same action as when a user clicks the Forward button in the
browser. The forward method works the same as history.go(1). An error does not
occur if the user tries to go beyond the end of the history. Instead, the user remains at
the current page.

Applies To

history

See Also

back, go

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
getExpression Method hasChildNodes Method
Web Workshop | DHTML, HTML & CSS
go Method
Loads a URL from the History list.

Syntax

history.go(vLocation)

Parameters

vLocation Required. Variant that specifies an integer or a string. The integer indicates the relative position of the URL in the History list, and the
string indicates all or part of a URL in the browser history.

Return Value

No return value.

Remarks

An error does not occur if the user tries to go beyond the beginning or end of the
history. Instead, the user remains at the current page.

Applies To

history

See Also

back, forward

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
history Object Members
Contains information about the URLs visited by the client.

Properties

length

Methods

back , forward , go

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
Hn Element | Hn Object Members
Renders text in heading style.

Properties

accessKey , align , canHaveChildren , className ,


clientHeight , clientLeft , clientTop , clientWidth ,
currentStyle , dir , firstChild , id , innerHTML , innerText
, isTextEdit , lang , language , lastChild , nextSibling ,
nodeName , nodeType , nodeValue , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
outerHTML , outerText , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
recordNumber , runtimeStyle , scopeName ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
sourceIndex , style , tabIndex , tagName , tagUrn , title
, uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-yline-
breakbackgroundtext-aligndirectionborder-bottom-
colortext-justifypositionbackground-positionclearborder-
right-colorborder-rightword-spacingtoppadding-
leftlayout-grid-modepadding-bottomrightfont-
sizeborder-bottomoverflowletter-
spacingdisplayfloatfont-familymargin-
rightbehaviorword-breaktext-transformbackground-
repeatborder-top-stylelayout-grid-charbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
HR Element | HR Object Members
Draws a horizontal rule.

Properties

accessKey , align , className , color , firstChild , id ,


isTextEdit , language , lastChild , nextSibling ,
nodeName , nodeType , nodeValue , noShade ,
offsetHeight , offsetLeft , offsetParent , offsetTop ,
offsetWidth , outerHTML , outerText , parentElement ,
parentNode , parentTextEdit , previousSibling ,
readyState , recordNumber , runtimeStyle , scopeName
, size , sourceIndex , style , tabIndex , tagName ,
tagUrn , title , uniqueID , width

Methods

addBehavior , applyElement , attachEvent , blur ,


clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getElementsByTagName
, getExpression , hasChildNodes ,
insertAdjacentElement , insertAdjacentHTML ,
insertAdjacentText , mergeAttributes , releaseCapture ,
removeAttribute , removeBehavior , removeExpression ,
replaceAdjacentText , scrollIntoView , setAttribute ,
setCapture , setExpression , swapNode

Events

onbeforecut , onbeforepaste , onblur , onclick ,


oncontextmenu , oncopy , oncut , ondblclick , ondrag ,
ondragend , ondragenter , ondragleave , ondragover ,
ondragstart , ondrop , onfocus , onhelp , onkeydown ,
onkeypress , onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onresize , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpadding-rightpaddingborder-right-widthcursortext-
indentvisibilityborder-left-colormargin-lefttext-
autospaceleftlayout-grid-lineline-breaktext-alignborder-
bottom-colortext-justifypositionclearborder-right-
colorborder-righttoppadding-leftlayout-grid-
modeheightpadding-bottomrightborder-
bottomdisplayfloatmargin-rightbehaviorword-
breakborder-top-stylelayout-grid-charbottomclipborder-
styleborder-top-widthborder-topmargin-bottomborder-
left-styleborder-widthmarginlayout-gridborder-bottom-
stylelayout-grid-typelayout-grid-char-spacingborder-
leftborder-left-widthpadding-topborder-colorborder-
right-style

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
parent Property parentNode Property DHTML
Web Workshop | DHTML, HTML & CSS
parentElement Property
Retrieves the parent object in the object hierarchy.

Syntax

HTML N/A
Scripting [ oElement = ] object.parentElement

Possible Values

oElement Object that specifies parent.

The property is read-only with no default value.

Remarks

The topmost object returns null as its parent.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BGSOUND, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE,
CODE, COL, COLGROUP, COMMENT, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn,
HR, HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, ISINDEX, KBD, LABEL, LEGEND, LI, LINK,
LISTING, MAP, MARQUEE, MENU, NEXTID, NOBR, NOFRAMES, NOSCRIPT, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP,
SCRIPT, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR, WBR,
XML, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
HTML Element | HTML Object Members
Identifies the document as containing HTML elements.

Properties

canHaveChildren , className , clientHeight , clientLeft ,


clientTop , clientWidth , currentStyle , firstChild , id ,
innerHTML , innerText , isTextEdit , lastChild ,
nextSibling , nodeName , nodeType , nodeValue ,
outerHTML , outerText , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tagName ,
tagUrn , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, clearAttributes , cloneNode , componentFromPoint ,
contains , detachEvent , getAdjacentText , getAttribute ,
getElementsByTagName , hasChildNodes ,
insertAdjacentElement , insertBefore , mergeAttributes ,
removeAttribute , removeBehavior , removeChild ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , setAttribute , swapNode

Events

onreadystatechange

Collections

all , attributes , behaviorUrns , childNodes , children


Behaviors

clientCaps , download , homePage

Styles

colorbackgroundfont-sizeletter-spacingbackground-
positionfontfont-familycursorbackground-colorfont-
weightbehaviorword-spacingtext-transformbackground-
repeatline-heightbackground-imagevisibilityfont-
stylebackground-attachmenttext-autospacefont-
varianttext-decoration

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
I Element | I Object Members
Specifies that the text should be rendered in italic, where
available.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagebottomvisibilityfont-
stylecliptext-autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright
Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
forms Collection images Collection DHTML Co
Web Workshop | DHTML, HTML & CSS
frames Collection
Retrieves a collection of all window objects defined by the given document or defined by
the document associated with the given window.

Syntax

[ collFrames = ] object.frames
[ oObject = ] object.frames(vIndex [, iSubIndex] )

Possible Values

collFrames Array of window objects.


vIndex Required. Integer or string that specifies the element or collection to retrieve. If this parameter is an integer, the method returns the
element in the collection at the given position, where the first element has value 0, the second has 1, and so on. If this parameter is a
string and there is more than one element with the name or id property equal to the string, the method returns a collection of matching
elements.
iSubIndex Optional. Position of an element to retrieve. This parameter is used when vIndex is a string. The method uses the string to construct a
collection of all elements that have a name or id property equal to the string, and then retrieves from this collection the element at the
position specified by iSubIndex.

Members

Remarks

If the HTML source document contains a BODY tag, the collection contains one window
for each IFRAME object in the document. If the source document contains FRAMESET
tags, the collection contains one window for each FRAME tag in the document. In both
cases, the order is determined by the HTML source.

This collection contains only window objects and does not provide access to the
corresponding FRAME and IFRAME objects. To access these objects, use the all
collection for the document containing the objects.

Although you can use names with the item method on this collection, the method
never returns a collection. Instead, it always returns the first window having the given
name. To ensure that all windows are accessible, make sure that no two windows in a
document have the same name.

Example

This example in JScript® (compatible with ECMA 262 language specification) shows
how to display the URLs of the HTML documents contained in windows created by the
IFRAME objects in the document.

var frm = document.frames;


for (i=0; i < frm.length; i++)
alert(frm(i).location);

This example in JScript shows how to display the name of each window defined by
FRAME tags in the parent window of the current document.
var frm = window.parent.frames;
for (i=0; i < frm.length; i++)
alert(frm(i).name);

Applies To

document, window

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
IFRAME Element | IFRAME Object
Members
Creates inline floating frames.

Properties

align , canHaveChildren , className , dataFld , dataSrc


, firstChild , frameBorder , hspace , id , innerHTML ,
innerText , isTextEdit , lang , language , lastChild ,
marginHeight , marginWidth , name , nextSibling ,
nodeName , nodeType , nodeValue , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
outerHTML , outerText , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
recordNumber , runtimeStyle , scopeName , scrolling ,
sourceIndex , src , style , tabIndex , tagName , tagUrn ,
title , uniqueID , vspace

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getElementsByTagName
, getExpression , hasChildNodes ,
insertAdjacentElement , insertAdjacentHTML ,
insertAdjacentText , insertBefore , mergeAttributes ,
removeAttribute , removeBehavior , removeChild ,
removeExpression , removeNode , replaceAdjacentText ,
replaceChild , replaceNode , scrollIntoView , setAttribute
, setExpression , swapNode

Events
onblur , onfocus

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , time

Styles

border-top-colorwidthmargin-topborder-bottom-
widthborder-bottompadding-
rightfloatdisplaypaddingmargin-rightborder-right-
widthcursorbehaviorborder-top-
stylebottomvisibilityclipborder-left-colormargin-lefttext-
autospaceleftoverflow-xoverflow-yborder-styleborder-
topborder-top-widthborder-bottom-colormargin-
bottompositionclearborder-left-styleborder-right-
colorborder-rightmarginborder-widthtoppadding-
leftborder-bottom-stylelayout-gridborder-left-
widthborder-leftheightlayout-grid-modepadding-
toppadding-bottomborder-colorborder-right-
styleborderright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
anchors Collection DHTML Collections
Web Workshop | DHTML, HTML & CSS
all Collection
Returns a reference to the collection of elements contained by the object.

Syntax

[ collAll = ] object.all
[ oObject = ] object.all(vIndex [, iSubIndex])

Possible Values

collAll Array of elements contained by the object.


oObject Reference to an individual item in the array of elements contained by the object.
vIndex Required. Integer or string that specifies the element or collection to retrieve. If this parameter is an integer, the
method returns the element in the collection at the given position, where the first element has value 0, the
second has 1, and so on. If this parameter is a string and there is more than one element with the name or id
property equal to the string, the method returns a collection of matching elements.
iSubIndex Optional. Position of an element to retrieve. This parameter is used when vIndex is a string. The method uses
the string to construct a collection of all elements that have a name or id property equal to the string, and then
retrieves from this collection the element at the position specified by iSubIndex.

Members

Remarks

The all collection includes one element object for each valid HTML tag. If
a valid tag has a matching end tag, both tags are represented by the
same element object.

The collection returned by the document's all collection always includes a


reference to the HTML, HEAD, TITLE, and BODY objects regardless of
whether the tags are present in the document.

If the document contains invalid or unknown tags, the collection includes


one element object for each. Unlike valid end tags, unknown end tags
are represented by their own element objects. The order of the element
objects is the HTML source order. Although the collection indicates the
order of tags, it does not indicate hierarchy.

Example

This example in JScript® (compatible with ECMA 262 language


specification) shows how to display the names of all tags in the
document in the order the tags appear in the document.
for(i = 0; i < document.all.length; i++){
alert(document.all(i).tagName);
}

This example in JScript shows how to use the item method on the all
collection to retrieve all element objects for which the name property or
ID attribute is set to sample. Depending on the number of times the
name or ID is defined in the document, the item method returns null, a
single element object, or a collection of element objects. The value of the
length property of the collection determines whether item returns a
collection or a single object.

var oObject = document.all.item("sample");


if (oObject != null){
if (oObject.length != null){
for (i = 0; i < oObject.length; i++){
alert(oObject(i).tagName);
}
}
}
else{
alert(oObject.tagName);
}

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BGSOUND, BIG, BLOCKQUOTE, BODY, BUTTON,
CAPTION, CENTER, CITE, CODE, COL, COLGROUP, custom, DD, DEL, DFN, DIR, DIV, DL, document, DT, EM, EMBED,
FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn, HR, HTML, I, IFRAME, IMG, INS, KBD, LABEL, LEGEND, LI, LINK,
LISTING, MAP, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, Q, S, SAMP, SCRIPT, SELECT, SMALL, SPAN, STRIKE,
STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
IMG Element | IMG Object Members
Embeds an image or a video clip in the document.

Properties

accessKey , align , alt , border , className ,


clientHeight , clientLeft , clientTop , clientWidth ,
complete , currentStyle , dataFld , dataSrc , dir , dynsrc
, fileCreatedDate , fileModifiedDate , fileSize ,
fileUpdatedDate , firstChild , height , hspace , id , isMap
, isTextEdit , lang , language , lastChild , loop , lowsrc ,
name , nameProp , nextSibling , nodeName , nodeType
, nodeValue , offsetHeight , offsetLeft , offsetParent ,
offsetTop , offsetWidth , outerHTML , outerText ,
parentElement , parentNode , parentTextEdit ,
previousSibling , protocol , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , src , start , style ,
tabIndex , tagName , tagUrn , title , uniqueID , useMap
, vspace , width

Methods

addBehavior , applyElement , attachEvent , blur ,


clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeExpression ,
replaceAdjacentText , scrollIntoView , setAttribute ,
setCapture , setExpression , swapNode
Events

onabort , onbeforecopy , onbeforecut , onbeforepaste ,


onblur , onclick , oncontextmenu , oncopy , oncut ,
ondblclick , ondrag , ondragend , ondragenter ,
ondragleave , ondragover , ondragstart , ondrop ,
onerror , onfilterchange , onfocus , onhelp , onload ,
onlosecapture , onmousedown , onmousemove ,
onmouseout , onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children ,


filters

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpadding-rightpaddingborder-right-
widthcursorvertical-alignfiltervisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftfont-
variantbackgrounddirectionborder-bottom-
colorpositionbackground-positionclearborder-right-
colorborder-rightword-spacingtoppadding-leftlayout-
grid-modeheightpadding-bottomrightborder-
bottomletter-spacingdisplayfloatfont-familymargin-
rightbehaviorbackground-repeatborder-top-
stylebackground-imagebottomclipborder-styleborder-
top-widthborder-topmargin-bottomfontborder-left-
styleborder-widthmarginunicode-bidibackground-
colorfont-weightline-heightborder-bottom-stylelayout-
gridborder-left-widthborder-leftpadding-topborder-
colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
type Property TYPE Attribute | type Pro... DHT
Web Workshop | DHTML, HTML & CSS
TYPE Attribute | type Property
Retrieves the type of intrinsic control represented by the object.

Syntax

HTML <ELEMENTTYPE =sType ... >


Scripting [ sType = ] object.type

Possible Values

sType String that specifies one of the following values:


INPUT button Creates a button control.
checkbox Creates a checkbox for simple Boolean attributes or for attributes that can take
multiple values at the same time. The input consists of a number of check box
controls, each of which has the same name. Each selected check box generates a
separate name/value pair in the submitted data, even if this results in duplicate
names. The default value is on.
file Creates a file upload object.
hidden Creates a control hidden from the user, but the value of the value property is sent
with the submitted form.
image Creates an image control that can be clicked, causing the form to be immediately
submitted. The coordinates of the selected point are measured in pixels from the
upper-left corner of the image and are submitted with the form as two name/value
pairs. The x-coordinate is submitted under the name of the control with .x
appended, and the y-coordinate is submitted under the name of the control with .y
appended. Any value property is ignored. The image is specified by the src property,
exactly as for the IMG object.
password Creates a control similar to the text control, except that text is not displayed as the
user enters it.
radio Creates radio buttons used for mutually exclusive sets of values. Each radio button
control in the group should be given the same name. Only the selected radio button
in the group generates a name/value pair in the submitted data. Radio buttons
require an explicit value property.
reset Creates a button that resets the form's controls to their specified initial values. You
can specify the label to display on this button just as you can for the Submit button.
submit Creates a button that submits the form. Use the value attribute to specify a label
that cannot be edited and is displayed on the button. The default label is application-
specific. If the user clicks the Submit button to submit the form, and that button has
a name attribute specified, that button contributes a name/value pair to the
submitted data.
text Creates a single-line text-entry control. Use the value in conjunction with the size
and maxLength properties.
SELECT select-multiple Creates a list box from which the user can select multiple items.
select-one Creates a list box from which the user can select one item.
TEXTAREA textarea Creates multiple-line text-entry controls. Use this value with the size and maxLength
properties.

The property is read-only with a default value of text for the INPUT element, select-
one for the SELECT element, and textarea for the TEXTAREA element.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

As of Microsoft® Internet Explorer 5, the type property is read/write-once, but only


before an INPUT element created with the createElement method is added to the
document.
The SELECT element exposes only the type property.

Applies To

INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT type=password, INPUT type=radio,
INPUT type=reset, INPUT type=submit, INPUT type=text, SELECT, TEXTAREA

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
INS Element | INS Object Members
Specifies text that has been inserted into the document.

Properties

accessKey , canHaveChildren , className , currentStyle


, dir , firstChild , id , innerHTML , innerText , isTextEdit ,
lang , language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , sourceIndex , style ,
tabIndex , tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , cloneNode ,
componentFromPoint , detachEvent , focus ,
getAdjacentText , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement , insertBefore ,
mergeAttributes , removeBehavior , removeChild ,
removeExpression , removeNode , replaceAdjacentText ,
replaceChild , replaceNode , setExpression , swapNode

Events

onblur , onfocus , onreadystatechange

Collections

all , attributes , behaviorUrns , childNodes , children


Behaviors

clientCaps , download , homePage , time

Styles

widthdirectionoverflowpadding-
rightdisplaypaddingunicode-bidibehaviorpadding-
leftlayout-gridlayout-grid-modetext-autospacepadding-
topoverflow-xpadding-bottomoverflow-y

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
table-layout Attribute | ... tagUrn Property DH
Web Workshop | DHTML, HTML & CSS
tagName Property
Retrieves the tag name of the object.

Syntax

HTML N/A
Scripting [ sName = ] object.tagName

Possible Values

sName String that specifies the tag name.

The property is read-only with no default value.

Example

This example retrieves the tag name of an object that has the identifier specified in the
prompt window.

<SCRIPT>
var idValue = window.prompt("Get the tag with this ID:;
if (idValue != null) {
alert(document.all[idValue].tagName)
}
</SCRIPT>

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BASE, BASEFONT, BDO, BGSOUND, BIG, BLOCKQUOTE, BODY, BR, BUTTON, CAPTION, CENTER, CITE,
CODE, COL, COLGROUP, COMMENT, custom, DD, DEL, DFN, DIR, DIV, DL, DT, EM, EMBED, FIELDSET, FONT, FORM, FRAME, FRAMESET, HEAD, Hn,
HR, HTML, I, IFRAME, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, KBD, LABEL, LEGEND, LI, LINK, LISTING, MAP,
MARQUEE, MENU, META, NEXTID, NOBR, OBJECT, OL, OPTION, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SCRIPT, SELECT, SMALL, SPAN,
STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TITLE, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
ISINDEX Element | ISINDEX Object
Members
Causes the browser to display a dialog window that prompts
the user for a single line of input.

Properties

accessKey , className , clientHeight , clientLeft ,


clientTop , clientWidth , currentStyle , id , lang ,
language , parentElement , readyState , scopeName ,
scrollHeight , scrollLeft , scrollTop , scrollWidth ,
tabIndex , tagUrn

Methods

addBehavior , blur , componentFromPoint , focus ,


getBoundingClientRect , getClientRects ,
removeBehavior

Events

onblur , onfocus , onreadystatechange , onresize

Collections

behaviorUrns

Behaviors

clientCaps , download , homePage

Styles
border-top-colormargin-topfont-sizeborder-bottom-
widthborder-bottompage-break-beforeletter-
spacingfloatfont-familymargin-rightborder-right-
widthbehaviortext-transformbackground-repeatborder-
top-stylebackground-imagebottomtext-
indentvisibilityfont-styleclipborder-left-colormargin-
lefttext-autospaceleftfont-varianttext-
decorationbackgroundborder-stylecolorborder-
topborder-top-widthz-indexborder-bottom-colormargin-
bottompage-break-afterpositionbackground-
positionclearfontborder-left-styleborder-right-
colorborder-rightmarginborder-widthfont-
weightbackground-colorword-spacingline-
heighttopborder-bottom-styleheightborder-left-
widthborder-leftborder-colorborderborder-right-
styleright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
KBD Element | KBD Object Members
Renders text in a fixed-width font.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecut , onbeforepaste , onblur , onclick ,
oncontextmenu , oncut , ondblclick , ondrag ,
ondragend , ondragenter , ondragleave , ondragover ,
ondragstart , ondrop , onfocus , onhelp , onkeydown ,
onkeypress , onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onresize , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagebottomvisibilityfont-
stylecliptext-autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
FOR Attribute | htmlFor P... htmlText Property
Web Workshop | DHTML, HTML & CSS
FOR Attribute | htmlFor Property
Sets or retrieves the object to which the given label object is assigned.

Syntax

HTML <LABEL FOR = sID ... >


Scripting label.htmlFor [ =sID ]

Possible Values

sID String that specifies the identifier of the element to which the label element is assigned.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Applies To

LABEL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
@media Rule ACTION Attribute | action... DH
Web Workshop | DHTML, HTML & CSS
ACCESSKEY Attribute | accessKey Property
Sets or retrieves the accelerator key for the object.

Syntax

HTML <ELEMENT ACCESSKEY = sAccessKey ... >


Scripting object.accessKey [ = sAccessKey ]

Possible Values

sAccessKey String of characters that specify a key on an alphanumeric keyboard.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Remarks

By default, the accessKey property sets focus to the object. The object receives focus
when the user simultaneously presses the ALT key and the accelerator key assigned to
an object. Some controls perform an action after receiving focus. For example, using
accessKey on a button causes the onclick event to fire. By comparison, applying the
accessKey on a radio button causes the onclick event to fire and toggles the
checked property, visibly selecting or deselecting the control.

As of Internet Explorer 5, some scoped elements do not implicitly support the


accessKey property. Instead, they support the property by setting the TABINDEX
attribute to any valid negative or positive integer.

Example

This example uses the LABEL object and the accessKey property to set focus on a
text box. The rich text support in the LABEL object makes it possible to underline the
designated accessKey.

<LABEL FOR="fp1" ACCESSKEY="1">#<U>1</U>:


Press Alt+1 to set focus to textbox</LABEL>
<INPUT TYPE="text" NAME="T1" VALUE=text1 SIZE="20"
TABINDEX="1" ID="fp1">

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

A, ACRONYM, ADDRESS, APPLET, AREA, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, custom, DD, DEL, DFN, DIR, DIV,
DL, DT, EM, EMBED, FIELDSET, FONT, Hn, HR, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=image, INPUT
type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, INS, ISINDEX, KBD, LABEL, LEGEND, LI, LISTING,
MARQUEE, MARQUEE, MENU, OBJECT, OL, P, PLAINTEXT, PRE, Q, RT, RUBY, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP, TABLE,
TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
onchange Event oncontextmenu Event DHTM
Web Workshop | DHTML, HTML & CSS
onclick Event
Fires when the user clicks the left mouse button on the object.

Syntax

Inline HTML <ELEMENT onclick = "handler" ... > All platforms


Event property object.onclick = handler JScript (compatible with ECMA 262 language specification) only
Named script <SCRIPT FOR = object EVENT = onclick> Internet Explorer only

Remarks

Bubbles Yes
Cancels Yes
To
invoke Click the object.
Invoke the click method.
Press the ENTER key in a form.
Press the access key for a control.
Select an item in a combo box or list box by clicking the left mouse button or by pressing the arrow keys and then pressing the
ENTER key.

Default Initiates any action associated with the object. For example, if the user clicks an A object, the browser loads the document specified by
action the href property. To cancel the default behavior, set the returnValue property of the event object to FALSE.

If the user clicks the left mouse button, the onclick event for an object occurs only if
the mouse pointer is over the object and an onmousedown and an onmouseup event
occur in that order. For example, if the user clicks the mouse on the object but moves
the mouse pointer away from the object before releasing, no onclick event occurs.

The onclick event changes the value of a control in a group. This change initiates the
event for the group, not for the individual control. For example, if the user clicks a
radio button or check box in a group, the onclick event occurs after the
onbeforeupdate and onafterupdate events for the control group.

If the user clicks an object that can receive the input focus but does not already have
the focus, the onfocus event occurs for that object before the onclick event. If the
user double-clicks the left mouse button in a control, an ondblclick event occurs
immediately after the onclick event.

Although the onclick event is available on a large number of HTML elements, if a Web
page is to be accessible to keyboard users, you should restrict its use to the A, INPUT,
AREA, and BUTTON elements. These elements automatically allow keyboard access
through the TAB key, making Web pages that use the elements accessible to keyboard
users. For more information, please see the section on writing accessible Dynamic
HTML.

Event Object Properties

Although event handlers in the DHTML Object Model do not receive parameters
directly, the handler can query the event object for data.
Example

The following examples show how to use the onclick event handlers for the document.

Applies To

A, ADDRESS, APPLET, AREA, B, BDO, BIG, BLOCKQUOTE, BODY, BUTTON, CAPTION, CENTER, CITE, CODE, custom, DD, DFN, DIR, DIV, DL,
document, DT, EM, EMBED, FIELDSET, FONT, FORM, Hn, HR, I, IMG, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT
type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, KBD, LABEL, LEGEND, LI,
LISTING, MAP, MARQUEE, MENU, NEXTID, NOBR, OBJECT, OL, P, PLAINTEXT, PRE, RT, RUBY, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG,
SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP

See Also

click

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
LABEL Element | LABEL Object Members
Specifies a label for another element on the page.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle ,
dataFld , dataFormatAs , dataSrc , dir , firstChild ,
htmlFor , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncut , ondblclick , ondrag ,
ondragend , ondragenter , ondragleave , ondragover ,
ondragstart , ondrop , onfocus , onhelp , onkeydown ,
onkeypress , onkeyup , onlosecapture , onmousedown ,
onmousemove , onmouseout , onmouseover ,
onmouseup , onpaste , onpropertychange ,
onreadystatechange , onresize , onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , userData

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviortext-transformbackground-
repeatbackground-imagebottomvisibilityfont-
stylecliptext-autospaceleftoverflow-xfont-varianttext-
decorationoverflow-ybackgroundcolordirectionz-
indexpositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
LEGEND Element | LEGEND Object
Members
Inserts a caption into the box drawn by the FIELDSET
object.

Properties

accessKey , align , canHaveChildren , className ,


clientHeight , clientLeft , clientTop , clientWidth ,
currentStyle , dir , firstChild , id , innerHTML , innerText
, isTextEdit , lang , language , lastChild , nextSibling ,
nodeName , nodeType , nodeValue , offsetHeight ,
offsetLeft , offsetParent , offsetTop , offsetWidth ,
outerHTML , outerText , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , style , tabIndex , tagName ,
tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
onfocus , onhelp , onkeydown , onkeypress , onkeyup ,
onlosecapture , onmousedown , onmousemove ,
onmouseout , onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , time

Styles

widthfont-sizeoverflowpadding-rightletter-
spacingfloatdisplaypaddingfont-
familycursorbehaviorword-breaktext-
transformbackground-repeatbackground-
imagebottomvisibilityfont-stylecliptext-
autospaceleftoverflow-xfont-varianttext-
decorationoverflow-yline-
breakbackgroundcolordirectionz-indextext-
justifypositionbackground-positionclearfontunicode-
bidibackground-colorfont-weightword-spacingline-
heighttoppadding-leftlayout-gridlayout-grid-
modepadding-toppadding-bottomright

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
TRUESPEED Attribute | tru... type Property D
Web Workshop | DHTML, HTML & CSS
TYPE Attribute | type Property
Sets or retrieves the style of the list.

Syntax

HTML <ELEMENT TYPE = sType ... >


Scripting object.type [ = sType ]

Possible Values

sType String that specifies one of the following values:


1 Associate numbers with each item in an ordered list.
a Associate lowercase letters with each item in an ordered list.
A Associate uppercase letters with each item in an ordered list.
i Associate Roman numerals with each item in an ordered list.
I Associate Roman numerals with each item in an ordered list.
disc Associate a solid disc with each item in an unordered list.
circle Associate a hollow circle with each item in an unordered list.
square Associate a solid square with each item in an unordered list.

The property is read/write with a default value of 1 for an ordered list and a default
value of disc for an unordered list.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Example

This example uses the TYPE attribute to set the line item markers to lowercase Roman
numerals.

<OL TYPE="i">
<LI>First Item
<LI>Second Item
<LI>Third Item
</OL>

This feature requires Internet Explorer 4.0 or later. Click the icon below to install the
latest version. Then reload this page to view the sample.

Applies To

LI, OL, UL

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
LI Element | LI Object Members
Denotes one item in a list.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , type , uniqueID , value

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode

Events
onbeforecopy , onbeforecut , onbeforepaste , onblur ,
onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colorwidthmargin-topborder-bottom-
widthpage-break-beforepadding-rightpaddingborder-
right-widthcursortext-indentvisibilityfont-styleborder-
left-colormargin-lefttext-autospaceleftoverflow-xlayout-
grid-linefont-variantoverflow-ylist-styleline-breaklist-
style-typebackgroundtext-alignlist-style-
imagedirectionborder-bottom-colortext-
justifypositionbackground-positionclearborder-right-
colorborder-rightword-spacingtoppadding-leftlayout-
grid-modepadding-bottomrightfont-sizeborder-
bottomoverflowletter-spacingdisplayfloatfont-
familymargin-rightbehaviorword-breaktext-
transformbackground-repeatborder-top-stylelayout-
grid-charlist-style-positionbackground-
imagebottomcliptext-decorationcolorborder-styleborder-
top-widthborder-topz-indexmargin-bottompage-break-
afterfontborder-left-styleborder-widthmarginunicode-
bidibackground-colorfont-weightline-heightborder-
bottom-stylelayout-gridlayout-grid-typelayout-grid-
char-spacingborder-left-widthborder-leftpadding-
topborder-colorborder-right-styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
LINK Element | LINK Object Members
Enables the current document to establish links to external
documents.

Properties

currentStyle , disabled , firstChild , href , id , isTextEdit


, lastChild , media , name , nextSibling , nodeName ,
nodeType , nodeValue , parentElement , parentNode ,
parentTextEdit , previousSibling , readyState , rel , rev ,
runtimeStyle , scopeName , sourceIndex , style ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , applyElement , attachEvent ,


clearAttributes , cloneNode , componentFromPoint ,
contains , detachEvent , getAdjacentText , getAttribute ,
getBoundingClientRect , getClientRects ,
getElementsByTagName , hasChildNodes ,
insertAdjacentElement , mergeAttributes ,
removeAttribute , removeBehavior ,
replaceAdjacentText , setAttribute , swapNode

Events

onload , onreadystatechange

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors
clientCaps , download , homePage

Styles

widthbehaviortext-autospace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
Web Workshop | DHTML, HTML & CSS
LISTING Element | LISTING Object
Members
Renders text in a fixed-width font.

Properties

accessKey , canHaveChildren , className , clientHeight


, clientLeft , clientTop , clientWidth , currentStyle , dir ,
firstChild , id , innerHTML , innerText , isTextEdit , lang ,
language , lastChild , nextSibling , nodeName ,
nodeType , nodeValue , offsetHeight , offsetLeft ,
offsetParent , offsetTop , offsetWidth , outerHTML ,
outerText , parentElement , parentNode , parentTextEdit
, previousSibling , readyState , recordNumber ,
runtimeStyle , scopeName , scrollHeight , scrollLeft ,
scrollTop , scrollWidth , sourceIndex , style , tabIndex ,
tagName , tagUrn , title , uniqueID

Methods

addBehavior , appendChild , applyElement , attachEvent


, blur , clearAttributes , click , cloneNode ,
componentFromPoint , contains , detachEvent , focus ,
getAdjacentText , getAttribute , getBoundingClientRect ,
getClientRects , getElementsByTagName , getExpression
, hasChildNodes , insertAdjacentElement ,
insertAdjacentHTML , insertAdjacentText , insertBefore ,
mergeAttributes , releaseCapture , removeAttribute ,
removeBehavior , removeChild , removeExpression ,
removeNode , replaceAdjacentText , replaceChild ,
replaceNode , scrollIntoView , setAttribute , setCapture
, setExpression , swapNode
Events

onbeforecopy , onbeforecut , onbeforepaste , onblur ,


onclick , oncontextmenu , oncopy , oncut , ondblclick ,
ondrag , ondragend , ondragenter , ondragleave ,
ondragover , ondragstart , ondrop , onfocus , onhelp ,
onkeydown , onkeypress , onkeyup , onlosecapture ,
onmousedown , onmousemove , onmouseout ,
onmouseover , onmouseup , onpaste ,
onpropertychange , onreadystatechange , onresize ,
onselectstart

Collections

all , attributes , behaviorUrns , childNodes , children

Behaviors

clientCaps , download , homePage , httpFolder ,


saveFavorite , saveHistory , saveSnapshot , time ,
userData

Styles

border-top-colormargin-topborder-bottom-widthpage-
break-beforepadding-rightpaddingborder-right-
widthcursortext-indentvisibilityfont-styleborder-left-
colormargin-lefttext-autospaceleftoverflow-xlayout-grid-
linefont-variantoverflow-yline-breakbackgroundtext-
aligndirectionborder-bottom-colortext-
justifypositionbackground-positionclearborder-right-
colorborder-rightword-spacingtoppadding-leftlayout-
grid-modepadding-bottomrightfont-sizeborder-
bottomoverflowletter-spacingdisplayfloatfont-
familymargin-rightbehaviorword-breaktext-
transformbackground-repeatborder-top-stylelayout-
grid-charbackground-imagebottomcliptext-
decorationcolorborder-styleborder-top-widthborder-
topz-indexmargin-bottompage-break-afterfontborder-
left-styleborder-widthmarginunicode-bidibackground-
colorfont-weightline-heightborder-bottom-stylelayout-
gridlayout-grid-typelayout-grid-char-spacingborder-left-
widthborder-leftpadding-topborder-colorborder-right-
styleborder

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
HREF Attribute | href Pro... HSPACE Attribute |
Web Workshop | DHTML, HTML & CSS
href Property
Sets or retrieves the entire URL as a string.

Syntax

HTML N/A
Scripting location.href [ = sURL ]

Possible Values

sURL String that specifies a URL.

The property is read/write with no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet


Explorer 5. For more information, see dynamic properties .
I
Example

This example shows a select list of URLs. The user is taken to the URL selected from
the options, if the selection is different from the list's default value.

<SELECT
onchange="window.location.href=this.options[this.selectedIndex].
value">
<OPTION VALUE="http://www.microsoft.com/ie">Internet
Explorer</OPTION>
<OPTION VALUE="http://www.microsoft.com">Microsoft Home</OPTION>
<OPTION VALUE="http://msdn.microsoft.com">Developer
Network</OPTION>
</SELECT>

Applies To

HTML N/A
Scripting location

See Also

navigate

Did you find this topic useful? Suggestions for other topics? write us!
I
© 1999 microsoft corporation. all rights reserved. terms of use .
I
Web Workshop | DHTML, HTML & CSS
location Object Members
Contains information about the current URL.

Properties

hash , host , hostname , href , pathname , port ,


protocol , search

Methods

assign , reload , replace

Did you find this topic useful? Suggestions for other topics?
write us!
I
© 1999 microsoft corporation. all rights reserved. terms of
use .
I
URN Attribute | urn Prope... userAgent Property
Web Workshop | DHTML, HTML & CSS
USEMAP Attribute | useMap Proper