HTML Quotes tag
HTML there are two main tags used for quotes: <blockquote> and <q>. They use different purposes and are used in different contexts.
2024-08-21 18:47:42 - Sakala Code
HTML Quotes <blockquote> Tag
HTML <blockquote> tag is used to indicate a block-level quotation from another source. It is typically used for longer quotes and is often rendered with indentation.
<!DOCTYPE html>
<html lang="en">
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Blockquote With Example</title>
<style>
blockquote {
border-left: 2px solid #ccc;
padding-left: 10px;
margin-left: 0;
font-style: italic;
}
</style>
</head>
<body>
<blockquote>
<p>SakalaCode HTML Blockquote With Example</p>
</blockquote>
</body>
</html>
HTML Quotes <q> Tag
HTML <q> tag is used for inline quotations. It is typically used for shorter quotes that are part of a larger sentence. Most browsers automatically add quotation marks around the text inside the <q> tag.
<!DOCTYPE html> <html lang="en"> <head> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Q Tag with Example</title> </head> <body> <p>HTML <q>Q tag SakalaCode.</q>.</p> </body> </html>