SHARE
Facebook X Pinterest WhatsApp

How to Use HTML Callouts and Quotes

Jun 13, 2018

Callouts

A callout is similar to a suggestion found in user-defined graphical applications that occur when the mouse moves over anchor links or when the mouse moves over images with an alt or title attribute. Basically, there is a box of indifference and a very effective way to display the action request on the website between content blocks. Our call box design provides space for your call to action. These graphic design elements are used to draw attention to a piece of information.

Use the <div> container element for anchor and image elements or both combined. Unfortunately, the <aside> and <article> elements are not recognized by the IE browser. So, to improve the semantic markup for callouts, use the <div> container element. When the element has an image, then the element must be called the next, and if the element is an anchor, the <div> element must be placed after the opening anchor tag.

Example :

<html>
<ul class="callouts">
  <li class="callouts--top">Pattern 1</li>
  <li class="callouts--bottom">Pattern 2</li>  
  <li class="callouts--right">Pattern 3</li>
</ul>
<style>
body {
  font-family: calibri;
  padding: 15%;
}
p: {
  position: absolute;
  top: 35px;
  right: 35px;
}
.callouts {
  list-style-type: none;
}
li + li {
  margin-left: 4%;
}
.callouts li {
  display: inline-block;
  position: relative;
	width: 18%;
	height: 100px;
  padding: 15px;
	background-color: white;
  border: 3px solid #c1c1c1;
	border-radius: 40px;
	box-shadow: 0 0 10px grey;
}
.callouts--top:before {
	content: "";
	position: absolute;
	width: 0;
	height: 0;
	left: 23px;
	top: -42px;
  border: 10px solid transparent;
 border-bottom: 32px solid rgba(195,195,195,0.5);
  z-index: 3;
}
.callouts--top:after {
  content: "";
	position: absolute;
	width: 0;
	height: 0;
	left: 25px;
	top: -32px;
  border: 8px solid transparent;
  border-bottom: 25px solid #fff;
  z-index: 5;
}
.callouts--bottom:before {
	content: "";
	position: absolute;
	width: 0;
	height: 0;
	left: 23px;
	bottom: -42px;
  border: 10px solid transparent;
  border-top: 32px solid rgba(193,193,193,0.5);
  z-index: 2;
}
.callouts--bottom:after {
  content: "";
	position: absolute;
	width: 0;
	height: 0;
	left: 25px;
	bottom: -31px;
  border: 8px solid transparent;
  border-top: 24px solid #fff;
  z-index: 5;
}
.callouts--left:before {
	content: "";
	position: absolute;
	width: 0;
	height: 0;
	left: -42px;
	top: 17px;
  border: 10px solid transparent;
  border-right: 32px solid rgb(193,193,193); /* IE8 Fallback */
  border-right: 32px solid rgba(193,193,193,0.5);
  z-index: 2;
}
.callouts--left:after {
  content: "";
	position: absolute;
	width: 0;
	height: 0;
	left: -31px;
	top: 20px;
  border: 8px solid transparent;
  border-right: 24px solid #fff;
  z-index: 3;
}
.callouts--right:before {
	content: "";
	position: absolute;
	width: 0;
	height: 0;
	right: -40px;
	top: 17px;
  border: 10px solid transparent;
  border-left: 32px solid rgb(193,193,193); /* IE8 Fallback */
  border-left: 32px solid rgba(193,193,193,0.5);
  z-index: 2;
}
.callouts--right:after {
  content: "";
	position: absolute;
	width: 0;
	height: 0;
	right: -30px;
	top: 20px;
  border: 8px solid transparent;
  border-left: 24px solid #fff;
  z-index: 3;
}
 </body>
</html>

We tested a demo page using the callout code in the following great browsers: Firefox, Google Chrome, Internet Explorer, Opera and Safari.

Quotes

The quote property specifies quotation marks for any number of embedded quotations. In the following lines, we will try the simplest example to build ourselves. There are four values for the content property that relate to the quotes property: open-quote, close-quote, no-open-quote, and no-close-quote.

Browser acceptance

Quotes are supported by all major browsers like: Firefox, Google Chrome, Internet Explorer, Opera and Safari.

Example:

<html>
<h2>Code example where we have a quote</h2>
<body>
<p>Theodor Seuss Geisel said :<br>
<br>
<q>You know you're in love when you can't fall asleep because reality is finally better than your dreams</q><br>
<br>
Dr. Seus
</p>
</body>
</html>

We can also display quotes as cards

The HTML <blockquote> element

This HTML element indicates that the inserted text is an extended quote. A quote source URL can be given by the attribute, and a text representation of the source can be given using the <cite>.

Example here :

<html>
<body>
<h2>About blockquote  element</h2>
<p>Here is a quote from goodreads website:</p>
<blockquote cite="https://www.goodreads.com/author/quotes/1744830.William_W_Purkey">
You've gotta dance like there's nobody watching,<br>
Love like you'll never be hurt,<br>
Sing like there's nobody listening,<br>
And live like it's heaven on earth.<br>
</blockquote>
</body>
</html>

The HTML citation element ( <cite> )

This HTML element is used to describe a reference to a quoted work, including the URL of the paper or the title. The reference may be abbreviated. In the context of the <cite> element, a creative work could be one of the following: an essay, a book, a song, a film, an exhibition, a web site, a painting, a sculpture and so on.

Example :

<html>
<head>
<style>
cite { 
    font-style: calibri;
}
</style>
</head>
<body>
<img src="https://upload.wikimedia.org/wikipedia/commons/3/31/Claude_Monet_023.jpg" width="220" height="277" alt="Study of a Figure Outdoors: Woman with a Parasol, facing left">
<p>A cite element is displayed like this:</p>
<p><cite>Study of a Figure Outdoors: Woman with a Parasol, <br>facing left</cite> by Edward Munch. Painted in 1893.</p>
</body>
</html>

The HTML abbreviation element ( <abbr> )

This HTML element is an abbreviation, and the title attribute can provide a description of the abbreviation. If present, the title should contain this complete description and nothing else. The title attribute has a specific meaning when we use it with the <abbr> element. As I said, it must contain a complete description. Each element <abbr> that we use is independent of all the others.

Example :

<html>
<body>
<p>The <abbr title="The United Nations International Children's Emergency Fund">UNICEF</abbr> was founded in 11 DECEMBER 1946.</p>
<p>UNICEF is a United Nations (UN) program headquartered in New York City that provides humanitarian and developmental assistance to children and mothers in developing countries. It is a member of the United Nations Development Group..</p>
</body>
</html>

The HTML address element ( <address> )

The <address> HTML element indicates that the HTML code provides contact information for a person / people or for an organization. The information related to the <address> element may be of any form and may include any contact information (the name of the person (s) or organization to which the contact information refers, the e-mail address, physical address, address URL, coordinate and so on).

Example :

<html>
<body>
<p>The address HTML element indicates that the HTML code provides contact information for a person / people or for an organization. </p>
<address>
Written by Albert Camus.<br> 
Visit us at:<br>
https://camus-society.com/<br>
Box 120, California<br>
USA
</address>
</body>
</html>

Recommended for you...

Best VR Game Development Platforms
Enrique Corrales
Jul 21, 2022
Best Online Courses to Learn HTML
Ronnie Payne
Jul 7, 2022
Working with HTML Images
Octavia Anghel
Jun 30, 2022
Web 3.0 and the Future Of Web Development
Rob Gravelle
Jun 23, 2022
HTML Goodies Logo

The original home of HTML tutorials. HTMLGoodies is a website dedicated to publishing tutorials that cover every aspect of being a web developer. We cover programming and web development tutorials on languages and technologies such as HTML, JavaScript, and CSS. In addition, our articles cover web frameworks like Angular and React.JS, as well as popular Content Management Systems (CMS) that include WordPress, Drupal, and Joomla. Website development platforms like Shopify, Squarespace, and Wix are also featured. Topics related to solid web design and Internet Marketing also find a home on HTMLGoodies, as we discuss UX/UI Design, Search Engine Optimization (SEO), and web dev best practices.

Property of TechnologyAdvice. © 2025 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.