Visit Mozilla.org

HTML:Element:code

From MDC

Contents

[edit] HTML Code Element

<code>...</code> - The HTML Code Element produces an inline element displayed in the browser's default monotype font (Lucida Console). This element was intended to identify a fragment of computer code, but commonly is used to style any text in a fixed width font.

[edit] Example

   Regular text. <code>This is code.</code> Regular text.

[edit] Result

Regular text. This is code. Regular text.

[edit] Note

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

[edit] See also


HTML Elements
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
(Quick Links: HTML Element Cross Reference, HTML Category)