😄 This post is based on the content from coding.courses.
Definition and Usage
The cite attribute specifies a URL that references the source of a quote or change.
This attribute is used with tags such as <q>, <blockquote>, <ins>, and <del>.
It enhances information credibility by providing source details for quotes or changes, enabling authors and search engines to utilize this information.
Basic Example
<p>
Tim Berners-Lee said:
<q cite="https://example.com/example">
The internet is a human right.
</q>
</p>
Examples
# Using the cite Attribute with <q>
<p>
Here is a famous quote:
<q cite="https://www.brainyquote.com/quotes/albert_einstein_100134">
Imagination is limitless. Knowledge is limited.
</q>
</p>
# Using the cite Attribute with <blockquote>
<p>The following is a quotation from Wikipedia.</p>
<blockquote cite="https://en.wikipedia.org/wiki/Romeo_and_Juliet">
<p>
The Tragedy of Romeo and Juliet, often shortened to Romeo and Juliet,
is a tragedy written by William Shakespeare about the romance
between two young Italians from feuding families.
It was among Shakespeare's most popular plays during his lifetime and,
along with Hamlet, is one of his most frequently performed. Today,
the title characters are regarded as archetypal young lovers.
</p>
</blockquote>
# Using the cite Attribute with <ins>
<p>
Here is a description of the latest update:
<ins cite="https://example.com/changelog">
Latest update details...
</ins>
</p>
# Using the cite Attribute with <del>
<p>
The following feature has been removed:
<del cite="https://example.com/changelog">
Details about the removed feature...
</del>
</p>
Top comments (0)