HTML Element Style How to - Add Quotes to blockquote








Question

We would like to know how to add Quotes to blockquote.

Answer


<!--from  w w w.j a va2s .c  om-->
<html>

<head>
<style>
blockquote:before {
  content: open-quote;
}

blockquote:after {
  content: close-quote;
}
</style>
</head>

<body>
  <h1>Generated quotes</h1>
  <p>Here are some quotes from Oscar Wilde:</p>

  <blockquote>This is a quote.</blockquote>

  <blockquote>This is a quote.</blockquote>

  <blockquote>This is a quote.</blockquote>
</body>
</html>

The code above is rendered as follows: