- <!--...-->
- <!DOCTYPE> Declaration
- <a>
- <abbr>
- <acronym>
- <address>
- <applet>
- <area>
- <article>
- <aside>
- <audio>
- <b>
- <base>
- <basefont>
- <bdi>
- <bdo>
- <big>
- <blockquote>
- <body>
- <br>
- <button>
- <canvas>
- <caption>
- <center>
- <cite>
- <code>
- <col>
- <colgroup>
- <data>
- <datalist>
- <dd>
- <del>
- <details>
- <dfn>
- <dialog>
- <dir>
- <div>
- <dl>
- <dt>
- <em>
- <embed>
- <fieldset>
- <figcaption>
- <figure>
- <font>
- <footer>
- <form>
- <frame>
- <frameset>
- <h1> to <h6> s
- <head>
- <header>
- <hgroup>
- <hr>
- <html>
- <i>
- <iframe>
- <img>
- <input>
- <ins>
- <kbd>
- <label>
- <legend>
- <li>
- <link>
- <main>
- <map>
- <mark>
- <menu>
- <meta>
- <meter>
- <nav>
- <noframes>
- <noscript>
- <object>
- <ol>
- <optgroup>
- <option>
- <output>
- <p>
- <param>
- <picture>
- <pre>
- <progress>
- <q>
- <rp>
- <rt>
- <ruby>
- <s>
- <samp>
- <script>
- <search>
- <section>
- <select>
- <small>
- <source>
- <span>
- <strike>
- <strong>
- <style>
- <sub>
- <summary>
- <sup>
- <svg>
- <table>
- <tbody>
- <td>
- <template>
- <textarea>
- <tfoot>
- <th>
- <thead>
- <time>
- <title>
- <tr>
- <track>
- <tt>
- <u>
- <ul>
- <var>
- <video>
- <wbr>
HTML <q> Tag
Example
Mark up a short quotation:
<p>WWF's goal is to:
<q>Build a future where people live in harmony with nature.</q>
We hope they succeed.</p>
More "Try it Yourself" examples below.
Definition and Usage
The <q>
tag defines a short quotation.
Browsers normally insert quotation marks around the quotation.
Tip: Use <blockquote> for long quotations.
Browser Support
Element | |||||
---|---|---|---|---|---|
<q> | Yes | Yes | Yes | Yes | Yes |
Attributes
Attribute | Value | Description |
---|---|---|
cite | URL | Specifies the source URL of the quote |
Global Attributes
The <q>
tag also supports the Global Attributes in HTML.
Event Attributes
The <q>
tag also supports the Event Attributes in HTML.
More Examples
Example
Use CSS to style the <q> element:
<html>
<head>
<style>
q {
color: gray;
font-style: italic;
}
</style>
</head>
<body>
<p>WWF's goal is to:
<q>Build a future where people live in harmony with nature.</q>
We hope they succeed.</p>
</body>
</html>
Related Pages
HTML DOM reference: Quote Object
Default CSS Settings
Most browsers will display the <q>
element with the following default values:
Example
q {
display: inline;
}
q:before {
content: open-quote;
}
q:after {
content: close-quote;
}
Виж примера display: inline;
}
q:before {
content: open-quote;
}
q:after {
content: close-quote;
}