1 | <HTML>
|
---|
2 | <!-- This file is part of the HTML Reference Library ('HTMLib') -->
|
---|
3 | <!-- It should not be used outside of the HTMLib package -->
|
---|
4 | <!-- The HTMLib is © 1995-1998 Stephen Le Hunte -->
|
---|
5 | <!-- htmlib@htmlib.demon.co.uk -->
|
---|
6 | <HEAD>
|
---|
7 | <LINK REL="stylesheet" HREF="../style.css" TYPE="text/css">
|
---|
8 | <TITLE><SAMP></TITLE>
|
---|
9 | </HEAD>
|
---|
10 | <BODY TOPMARGIN="0" BGCOLOR="#FFFFE0" TEXT="#000000">
|
---|
11 |
|
---|
12 | <CENTER>
|
---|
13 | <SPAN CLASS="NSRtitle"><SAMP...></SPAN>
|
---|
14 | </CENTER>
|
---|
15 |
|
---|
16 | <P>The Sample element can be used to indicate a sequence of literal characters and is typically rendered in a mono spaced font.
|
---|
17 |
|
---|
18 | <SPAN CLASS="egcode">
|
---|
19 | <BLOCKQUOTE>
|
---|
20 | <CODE>A sequence of <STRONG><SAMP></STRONG>literal characters<STRONG></SAMP></STRONG> commonly renders in a monospaced font.
|
---|
21 | </CODE>
|
---|
22 | </BLOCKQUOTE>
|
---|
23 | </SPAN>
|
---|
24 |
|
---|
25 | <P>would render as :
|
---|
26 |
|
---|
27 | <P><BLOCKQUOTE>A sequence of <SAMP>literal characters</SAMP> commonly renders in a mono spaced font.
|
---|
28 | </BLOCKQUOTE>
|
---|
29 |
|
---|
30 | <P><A NAME="TITLE"><SPAN CLASS="attr">TITLE</SPAN></A>="informational ToolTip"<BR>
|
---|
31 | The <STRONG>Internet Explorer</STRONG> 4.0 (and above) specific <CODE>TITLE</CODE> attribute is used for informational purposes. If present, the value of the <CODE>TITLE</CODE> attribute is presented as a ToolTip when the users mouse hovers over the <CODE><SAMP></CODE> section.
|
---|
32 |
|
---|
33 | <P><A NAME="LANG"><SPAN CLASS="attr">LANG</SPAN></A>="language setting"<BR>
|
---|
34 | The <CODE>LANG</CODE> attribute can be used to specify what language the <CODE><SAMP></CODE> element is using. It accepts any valid ISO standard language abbreviation (for example <CODE>"en"</CODE> for English, <CODE>"de"</CODE> for German etc.) For more details, see the <A HREF="../Document_Localisation/ov.htm" TITLE="View the HTML localisation topic">Document Localisation</A> section for more details.
|
---|
35 |
|
---|
36 | <P><A NAME="LANGUAGE"><SPAN CLASS="attr">LANGUAGE</SPAN></A>="Scripting language"<BR>
|
---|
37 | The <CODE>LANGUAGE</CODE> attribute can be used to expressly specify which scripting language <STRONG>Internet Explorer</STRONG> 4.0 uses to interpret any scripting information used in the <CODE><SAMP></CODE> element. It can accept values of <CODE>vbscript</CODE>, <CODE>vbs</CODE>, <CODE>javascript</CODE> or <CODE>jscript</CODE>. The first two specify the scripting language as Visual Basic Script, the latter two specify it as using Javascript (the default scripting language used if no <CODE>LANGUAGE</CODE> attribute is set.
|
---|
38 |
|
---|
39 | <P><A NAME="CLASS"><SPAN CLASS="attr">CLASS</SPAN></A>="Style Sheet class name"<BR>
|
---|
40 | The <CODE>CLASS</CODE> attribute is used to specify the <CODE><SAMP></CODE> element as using a particular style sheet class. See the <A HREF="../Style_Sheets/ov.htm" TITLE="View the Style Sheets overview">Style Sheets</A> topic for details.
|
---|
41 |
|
---|
42 | <P><A NAME="STYLE"><SPAN CLASS="attr">STYLE</SPAN></A>="In line style setting"<BR>
|
---|
43 | As well as using previously defined style sheet settings, the <CODE><SAMP></CODE> element can have in-line stylings attached to it. See the <A HREF="../Style_Sheets/ov.htm" TITLE="View the Style Sheets overview">Style Sheets</A> topic for details.
|
---|
44 |
|
---|
45 | <P><A NAME="ID"><SPAN CLASS="attr">ID</SPAN></A>="Unique element identifier"<BR>
|
---|
46 | The <CODE>ID</CODE> attribute can be used to either reference a unique style sheet identifier, or to provide a unique name for the <CODE><SAMP></CODE> element for scripting purposes. Any <CODE><SAMP></CODE> element with an <CODE>ID</CODE> attribute can be directly manipulated in script by referencing its <CODE>ID</CODE> attribute, rather than working through the <A HREF="../Scripting_Reference/allcol.htm" TITLE="View the All collection topic">All collection</A> to determine the element. See the <A HREF="../Scripting_Reference/ov.htm" TITLE="View the Scripting Introduction topic">Scripting introduction</A> topic for more information.
|
---|
47 |
|
---|
48 | <P><HR WIDTH="75%" ALIGN="center">
|
---|
49 |
|
---|
50 | <P>Every <CODE><SAMP></CODE> element in a document is an object that can be manipulated through scripting. Note that scripting of the <CODE><SAMP></CODE> element/object is only supported by <STRONG>Internet Explorer</STRONG> 4.0 in its <A HREF="../Dynamic_HTML/dhtml.htm" TITLE="View the Dynamic HTML Overview">Dynamic HTML</A> object model. <STRONG>Netscape</STRONG> does not support direct scripting of the <CODE><SAMP></CODE> element at all.
|
---|
51 |
|
---|
52 | <P><A NAME="SAMP_Properties" TITLE=""><STRONG><CODE><SAMP...></CODE> Properties</STRONG></A><BR>
|
---|
53 | The <CODE><SAMP...></CODE> element/object supports <EM>all</EM> of the standard <A HREF="../Dynamic_HTML/dhtml.htm" TITLE="View the Dynamic HTML overview topic">Dynamic HTML</A> properties (i.e. <SPAN CLASS="attr">className</SPAN>, <SPAN CLASS="attr">document</SPAN>, <SPAN CLASS="attr">id</SPAN>, <SPAN CLASS="attr">innerHTML</SPAN>, <SPAN CLASS="attr">innerText</SPAN>, <SPAN CLASS="attr">isTextEdit</SPAN>, <SPAN CLASS="attr">lang</SPAN>, <SPAN CLASS="attr">language</SPAN>, <SPAN CLASS="attr">offsetHeight</SPAN>, <SPAN CLASS="attr">offsetLeft</SPAN>, <SPAN CLASS="attr">offsetParent</SPAN>, <SPAN CLASS="attr">offsetTop</SPAN>, <SPAN CLASS="attr">offsetWidth</SPAN>, <SPAN CLASS="attr">outerHTML</SPAN>, <SPAN CLASS="attr">outerText</SPAN>, <SPAN CLASS="attr">parentElement</SPAN>, <SPAN CLASS="attr">parentTextEdit</SPAN>, <SPAN CLASS="attr">sourceIndex</SPAN>, <SPAN CLASS="attr">style</SPAN>, <SPAN CLASS="attr">tagName</SPAN> and <SPAN CLASS="attr">title</SPAN>). Details of these can be found in the <A HREF="../Dynamic_HTML/dhtmlp.htm" TITLE="View the standard Dynamic HTML Properties topic">standard Dynamic HTML properties</A> topics.
|
---|
54 |
|
---|
55 | <P><A NAME="SAMP_Methods" TITLE=""><STRONG><CODE><SAMP...></CODE> Methods</STRONG></A><BR>
|
---|
56 | The <CODE><SAMP...></CODE> element/object supports <EM>all</EM> of the standard <A HREF="../Dynamic_HTML/dhtml.htm" TITLE="View the Dynamic HTML overview topic">Dynamic HTML</A> methods (i.e. <SPAN CLASS="attr">click</SPAN>, <SPAN CLASS="attr">contains</SPAN>, <SPAN CLASS="attr">getAttribute</SPAN>, <SPAN CLASS="attr">insertAdjacentHTML</SPAN>, <SPAN CLASS="attr">insertAdjacentText</SPAN>, <SPAN CLASS="attr">removeAttribute</SPAN>, <SPAN CLASS="attr">scrollIntoView</SPAN> and <SPAN CLASS="attr">setAttribute</SPAN>). Details of these can be found in the <A HREF="../Dynamic_HTML/dhtmlm.htm" TITLE="View the standard Dynamic HTML Methods topic">standard Dynamic HTML Methods</A> topics.
|
---|
57 |
|
---|
58 | <P><A NAME="SAMP_Events" TITLE=""><STRONG><CODE><SAMP...></CODE> Events</STRONG></A><BR>
|
---|
59 | The <CODE><SAMP...></CODE> element/object supports <EM>all</EM> of the standard <A HREF="../Dynamic_HTML/dhtml.htm" TITLE="View the Dynamic HTML overview topic">Dynamic HTML</A> events (i.e. <SPAN CLASS="attr">onclick</SPAN>, <SPAN CLASS="attr">ondblclick</SPAN>, <SPAN CLASS="attr">ondragstart</SPAN>, <SPAN CLASS="attr">onfilterchange</SPAN>, <SPAN CLASS="attr">onhelp</SPAN>, <SPAN CLASS="attr">onkeydown</SPAN>, <SPAN CLASS="attr">onkeypress</SPAN>, <SPAN CLASS="attr">onkeyup</SPAN>, <SPAN CLASS="attr">onmousedown</SPAN>, <SPAN CLASS="attr">onmousemove</SPAN>, <SPAN CLASS="attr">onmouseout</SPAN>, <SPAN CLASS="attr">onmouseover</SPAN>, <SPAN CLASS="attr">onmouseup</SPAN> and <SPAN CLASS="attr">onselectstart</SPAN>). Details of these can be found in the <A HREF="../Dynamic_HTML/dhtmle.htm" TITLE="View the standard Dynamic HTML Events topic">standard Dynamic HTML events</A> topics.
|
---|
60 |
|
---|
61 |
|
---|
62 | <P>
|
---|
63 |
|
---|
64 | <P ALIGN="right" CLASS="copyright">© 1995-1998, Stephen Le Hunte</P>
|
---|
65 | </BODY>
|
---|
66 | </HTML>
|
---|