Note, if you are using the Visual Editor, with the default settings, you cannot use instead of. Save this and you should get a text box similar to this one: Immediately before the text and immediately after it. When you are finished, go to the Code tab page and locate the paragraph to go in the box. It is simple to use inline CSS to create a box around a paragraph.įirst, use the default WordPress Editor (ie the Visual tab page) to write the entire post, including the text you want displayed in a text box. I don’t cover that in this article, as it would make it too long, but you can read about it in my Rounded Text Boxes in Posts article. If you’re interested in text boxes with rounded corners, this is a little more difficult (but so much cooler). The information is available, but the formatting separates it from the main body of the post in the reader’s mind.īooks and websites often use this technique, so why not inside posts? It’s possible to use blockquotes for this purpose, but I wanted to keep that for quoting other people, so I decided to create text boxes using CSS. The ideal way to include this sort of information is in a text box with formatting that sets it apart. For example, additional information that may be useful to readers, but that disrupts the flow of the post.
I often have information that I want to include in a post, without it being part of the main body of the article.
You’ll be surprised at how easy it is to do!
#How to make text smaller in a css how to#
In this article, I outline how to create simple text boxes using both inline and external CSS and how to set up a quicktag button so you can use them with the minimum of effort.