{"id":77551,"date":"2012-05-07T12:00:09","date_gmt":"2012-05-07T16:00:09","guid":{"rendered":"http:\/\/wpmu.org\/?p=77551"},"modified":"2012-05-07T01:04:06","modified_gmt":"2012-05-07T05:04:06","slug":"how-to-create-drop-caps-big-first-letters-in-wordpress","status":"publish","type":"post","link":"https:\/\/wpmudev.com\/blog\/how-to-create-drop-caps-big-first-letters-in-wordpress\/","title":{"rendered":"How to Create Drop Caps (Big First Letters) in WordPress"},"content":{"rendered":"<p><a rel=\"lightbox[77551]\" class=\"blog-thumbnail\" href=\"https:\/\/wpmudev.com\/blog\/how-to-create-drop-caps-big-first-letters-in-wordpress\/d-big\/\" rel=\"attachment wp-att-77552\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-77552\" title=\"d-big\" src=\"https:\/\/wpmudev.com\/blog\/wp-content\/uploads\/2012\/05\/d-big.jpg\" alt=\"Post image\" aria-hidden=\"true\" width=\"653\" height=\"466\" \/><\/a><br \/>\nWe\u2019ve all seen drop caps, but perhaps you weren\u2019t familiar with their technical name. Drops caps are those big first letters that you see at the beginning of paragraphs. They are common in magazines and newspapers, but not so much on the web.<\/p>\n<p>If you\u2019d like to style up your posts with a drop cap, it\u2019s easy enough to do. There are several ways to go about it.<\/p>\n<p>&nbsp;<\/p>\n<h2><strong>Place CSS Code in Your Stylesheet<\/strong><\/h2>\n<p>The first way is to place some CSS code in your Stylesheet.<\/p>\n<p>You will need to know the name of the div class for your main content. You can find that by looking in\u00a0 your theme files. For example, in the default TwentyTen theme from WordPress, you can see the div class is called \u201centry-content\u201d for the single post file (loop-single.php).<\/p>\n<p><a rel=\"lightbox[77551]\" class=\"blog-thumbnail\" href=\"https:\/\/wpmudev.com\/blog\/how-to-create-drop-caps-big-first-letters-in-wordpress\/div-class\/\" rel=\"attachment wp-att-77554\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-77554\" title=\"div-class\" src=\"https:\/\/wpmudev.com\/blog\/wp-content\/uploads\/2012\/05\/div-class.jpg\" alt=\"Post image\" aria-hidden=\"true\" width=\"632\" height=\"286\" \/><\/a>There\u2019s a good chance that your theme is named in the same way, but it might not be, so you\u2019ll need to check it.<\/p>\n<p>Once you have your div class, then place the following code in your Stylesheet. (Appearance &gt; Editor &gt; Stylesheet \u2013 style.css)<\/p>\n<p>You\u2019ll need to change the \u201centry-content\u201d section below if your theme has a different class name. You can also change the properties to make it look the way you like, even adding more properties, of course. In this example, I\u2019ve made a blue drop cap with a shadow.<\/p>\n<p>&nbsp;<\/p>\n<pre>div.entry-content p:first-child:first-letter {\r\nfloat:left;\r\nfont-size:4em;\r\ncolor: #000099;\r\nmargin-right:0.10em;\r\nline-height:90%;\r\ntext-shadow: 0.05em 0.05em #C0C0C0;\r\n}<\/pre>\n<p>&nbsp;<\/p>\n<p>And here\u2019s the result:<\/p>\n<p><a rel=\"lightbox[77551]\" class=\"blog-thumbnail\" href=\"https:\/\/wpmudev.com\/blog\/how-to-create-drop-caps-big-first-letters-in-wordpress\/blue-drop-cap\/\" rel=\"attachment wp-att-77555\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-77555\" title=\"blue-drop-cap\" src=\"https:\/\/wpmudev.com\/blog\/wp-content\/uploads\/2012\/05\/blue-drop-cap.jpg\" alt=\"Post image\" aria-hidden=\"true\" width=\"632\" height=\"398\" \/><\/a><\/p>\n\n<h2><strong>Use a Plugin<\/strong><\/h2>\n<p>Another way to achieve a drop cap is with the <a href=\"http:\/\/wordpress.org\/extend\/plugins\/drop-caps\/\" target=\"_blank\">Drop Caps<\/a> plugin. This plugin gives the novice a little more flexibility with less work.<\/p>\n<p>This plugin lets you easily choose where drop caps should appear and where they shouldn\u2019t: on content, on excepts, on single posts, on pages, on the homepage, etc. It also lets you exclude specific posts or categories.<\/p>\n<p><a rel=\"lightbox[77551]\" class=\"blog-thumbnail\" href=\"https:\/\/wpmudev.com\/blog\/how-to-create-drop-caps-big-first-letters-in-wordpress\/settings-19\/\" rel=\"attachment wp-att-77556\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-77556\" title=\"settings\" src=\"https:\/\/wpmudev.com\/blog\/wp-content\/uploads\/2012\/05\/settings1.jpg\" alt=\"Post image\" aria-hidden=\"true\" width=\"630\" height=\"513\" \/><\/a><\/p>\n<p>Here\u2019s the default look for the Drop Caps plugin, but it does also give you the option of inserting your own CSS in your Stylesheet.<\/p>\n<p><a rel=\"lightbox[77551]\" class=\"blog-thumbnail\" href=\"https:\/\/wpmudev.com\/blog\/how-to-create-drop-caps-big-first-letters-in-wordpress\/drop-caps-plugin\/\" rel=\"attachment wp-att-77557\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-77557\" title=\"drop-caps-plugin\" src=\"https:\/\/wpmudev.com\/blog\/wp-content\/uploads\/2012\/05\/drop-caps-plugin.jpg\" alt=\"Post image\" aria-hidden=\"true\" width=\"630\" height=\"404\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n\n<p>&nbsp;<\/p>\n<p>Photo: <a href=\"http:\/\/www.bigstockphoto.com\/image-25022579\/stock-vector-ornamental-letter-d-vector\" target=\"_blank\">ornamental letter &#8211; D- vector<\/a> from BigStock<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Use one of the following ways to style your posts like a magazine article.<\/p>\n","protected":false},"author":84404,"featured_media":77553,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"blog_reading_time":"","wds_primary_category":0,"wds_primary_tutorials_categories":0,"footnotes":""},"categories":[4],"tags":[],"tutorials_categories":[],"class_list":["post-77551","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-plugins"],"_links":{"self":[{"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/posts\/77551","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/users\/84404"}],"replies":[{"embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/comments?post=77551"}],"version-history":[{"count":1,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/posts\/77551\/revisions"}],"predecessor-version":[{"id":216169,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/posts\/77551\/revisions\/216169"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/media\/77553"}],"wp:attachment":[{"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/media?parent=77551"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/categories?post=77551"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/tags?post=77551"},{"taxonomy":"tutorials_categories","embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/tutorials_categories?post=77551"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}