UPDATE: An error occurred in the code below when this post was published, it should be correct now. Please leave any problems or questions in the comments. Thanks!
So, have you ever been a little frustrated that there isn’t an easy way to change the text size or font when writing a WordPress post? Well, today I’m going to show you how to change the font type or size, using a little html. Don’t worry, its not as hard as it sounds. 🙂
In this example we are going to change a few words to be 24px.
First make sure you are in the “Text” editing mode…
You will see sets of code where you saw images when you were in the “Visual” tab and the text will look a little more mechanical. Find the text you want to change and put this at the beginning of it:
<span style=”font-size: 24px;”>
Then put </span> at the end of the text you want changed. MAKE SURE you do this part or all the text after that first part of code will be changed and things get royally messed up when you don’t close a piece of code.
So for example, if I wanted to make the text “MAKE SURE” above to be 24px the code in the text editing tab would look like:
<span style=”font-size: 24px;”>MAKE SURE</span>
And thats it! Pretty easy right? You can also use this to change other aspects of text such as the color or the font. (WordPress has a built in way to change the color of text though)
If you want to change the font of the text you would add font-family: ‘NAME OF FONT’; in between the parentheses, after that first semicolon. You do have to be careful with fonts though because if the person viewing your site doesn’t have that particular font on their computer they will not see that text in that font. So its best to stick with fonts that come default on the majority of computers OR there is a great resource called Google Web Fonts, but thats a tutorial for another time.
Leave any questions in the comments and I’ll try my best to help!