HTML - attributes - cite

revision:


Content

"cite" attribute: used to describe a reference to a cited work. syntax some examples


"cite" attribute: used to describe a reference to a cited work.

top

It specifies a URL to a document that explains the quote, or why the text was inserted/changed.

The <cite> HTML element must include the title of the referenced work. The reference may be in an abbreviated form according to context-appropriate conventions related to citation metadata.
The cite attribute can be used on the following elements: <blockquote>, <del>, <ins>, <q>.


syntax

top

<blockquote cite="value">.............. ><blockquote>

The cite attribute has no visual effect in ordinary web browsers, but can be used by screen readers. URL contains the value i.e URL which specifies the source of the quotation. Possible values are: absolute URL (i.e. it points to another website) or relative URL (i.e. it points to a file within a website).


some examples

top

Here is a quote from WWF's website:

For 50 years, WWF has been protecting the future of nature. The world's leading conservation organization, WWF works in 100 countries and is supported by 1.2 million members in the United States and close to 5 million globally.
codes:
                    <p class="spec" style="margin-left:5vw;">Here is a quote from WWF's website:</p>
                    <blockquote style="margin-left:5vw;" cite="http://www.worldwildlife.org/who/index.html">
                    For 50 years, WWF has been protecting the future of nature. The world's leading conservation
                    organization, WWF works in 100 countries and is supported by 1.2 million members in the United
                    States and close to 5 million globally.
                    </blockquote>
                

WWF's goal is to: Build a future where people live in harmony with nature. We hope they succeed.

codes:

                    <p class="spec" >WWF's goal is to:
                        <q cite="http://www.wwf.org">Build a future where people live in harmony with nature.</q>
                        We hope they succeed.
                        </p>