<samp>

  • Revision slug: HTML/Element/samp
  • Revision title: samp
  • Revision id: 22471
  • Created:
  • Creator: Jscher2000
  • Is current revision? No
  • Comment /* Result */

Revision Content

HTML Sample Text Element

<samp>...</samp> - The HTML Sample Text Element produces an inline element displayed in the browser's default monotype font (Lucida Console). This element was intended to identify sample output from a computer program.

Example

   Regular text. <samp>This is sample text.</samp> Regular text.

Result

Regular text. <samp>This is sample text.</samp> Regular text.

(This example appears not to work due to restrictions in the wiki software, but in real web pages it should be fine!)

Note

A CSS rule can be defined for the samp selector to override the browser's default font face. Preferences set by the user might take precedence over the specified CSS.

See also

{{wiki.template('HTML:Element_Navigation')}}

Revision Source

<h2 name="HTML_Sample_Text_Element"> HTML <i>Sample Text</i> Element </h2>
<p><b>&lt;samp&gt;...&lt;/samp&gt;</b> - The HTML Sample Text Element produces an inline element displayed in the browser's default monotype font (Lucida Console). This element was intended to identify sample output from a computer program.
</p>
<h3 name="Example"> Example </h3>
<pre class="eval">   Regular text. &lt;samp&gt;This is sample text.&lt;/samp&gt; Regular text.
</pre>
<h4 name="Result"> Result </h4>
    <p>Regular text. &lt;samp&gt;This is sample text.&lt;/samp&gt; Regular text.</p>
<p>(This example appears not to work due to restrictions in the wiki software, but in real web pages it should be fine!)
</p>
<h3 name="Note"> Note </h3>
<p>A CSS rule can be defined for the <code>samp</code> selector to override the browser's default font face. Preferences set by the user might take precedence over the specified CSS.
</p>
<h3 name="See_also"> See also </h3>
<ul><li> <a href="en/HTML/Element/code">HTML Code Element</a>
</li><li> HTML 4.01 Specification: <a class="external" href="http://www.w3.org/TR/html4/struct/text.html#h-9.2.1">Phrase Elements</a>
</li></ul>
<p>{{wiki.template('HTML:Element_Navigation')}}
</p>
Revert to this revision