(For more resources related to this topic, see here.)
Posting on your blog
The central activity you'll be doing with your blog is adding posts. A post is like an article in a magazine; it's got a title, content, and an author (in this case, you, though WordPress allows multiple authors to contribute to a blog). If a blog is like an online diary, every post is an entry in that diary. A blog post also has a lot of other information attached to it, such as a date, excerpt, tags, and categories. In this section, you will learn how to create a new post and what kind of information to attach to it.
Adding a simple post
Let's review the process of adding a simple post to your blog. Whenever you want to add content or carry out a maintenance process on your WordPress website, you have to start by logging in to the WP Admin (WordPress Administration panel) of your site. To get to the admin panel, just point your web browser to http://yoursite.com/wp-admin.
Remember that if you have installed WordPress in a subfolder (for example, blog), your URL has to include the subfolder (that is, http://yoursite.com/blog/wp-admin).
When you first log in to the WP Admin, you'll be at the Dashboard. The Dashboard has a lot of information on it so don't worry about that right now.
The quickest way to get to the Add New Post page at any time is to click on + New and then the Post link at the top of the page in the top bar.
This is the Add New Post page:
To add a new post to your site quickly, all you have to do is:
- Type in a title into the text field under Add New Post (for example, Making Lasagne).
- Type the text of your post in the content box. Note that the default view is Visual, but you actually have a choice of the Text view as well.
- Click on the Publish button, which is at the far right. Note that you can choose to save a draft or preview your post as well.
Once you click on the Publish button, you have to wait while WordPress performs its magic. You'll see yourself still on the Edit Post screen, but now the following message would have appeared telling you that your post was published, and giving you a link View post:
If you view the front page of your site, you'll see that your new post has been added at the top (newest posts are always at the top).
Common post options
Now that we've reviewed the basics of adding a post, let's investigate some of the other options on the Add New Post and Edit Post pages. In this section we'll look at the most commonly used options, and in the next section we'll look at the more advanced options.
Categories and tags
Categories and tags are two types of information that you can add to a blog post. We use them to organize the information in your blog by topic and content (rather than just by, say, date), and to help visitors find what they are looking for on your blog.
Categories are primarily used for structural organizing. They can be hierarchical, meaning a category can be a parent of another category. A relatively busy blog will probably have at least 10 categories, but probably not more than 15 or 20. Each post in such a blog is likely to have from one up to, maybe four categories assigned to it.
For example, a blog about food and cooking might have these categories: Cooking Adventures, In The Media, Ingredients, Opinion, Recipes Found, Recipes Invented, and Restaurants. Of course, the numbers mentioned are just suggestions; you can create and assign as many categories as you like. The way you structure your categories is entirely up to you as well. There are no true rules regarding this in the WordPress world, just guidelines like these.
Tags are primarily used as shorthand for describing the topics covered in a particular blog post. A relatively busy blog will have anywhere from 15 to even 100 tags in use. Each post in this blog is likely to have 3 to 10 tags assigned to it. For example, a post on the food blog about a recipe for butternut squash soup may have these tags: soup, vegetarian, autumn, hot, and easy. Again, you can create and assign as many tags as you like.
Let's add a new post to the blog. After you give it a title and content, let's add tags and categories. While adding tags, just type your list of tags into the Tags box on the right, separated by commas:
Then click on the Add button. The tags you just typed in will appear below the text field with little x buttons next to them. You can click on an x button to delete a tag. Once you've used some tags in your blog, you'll be able to click on the Choose from the most used tags link in this box so that you can easily re-use tags.
Categories work a bit differently than tags. Once you get your blog going, you'll usually just check the boxes next to existing categories in the Categories box. In this case, as we don't have any existing categories, we'll have to add one or two.
In the Categories box on the right, click on the + Add New Category link. Type your category into the text field, and click on the Add New Category button. Your new category will show up in the list, already checked. Look at the following screenshot:
If in the future you want to add a category that needs a parent category, select — Parent Category — from the pull-down menu before clicking on the Add New Category button. If you want to manage more details about your categories, move them around, rename them, assign parent categories, and assign descriptive text. You can do so on the Categories page.
Click on the Publish button, and you're done (you can instead choose to schedule a post; we'll explore that in detail in a few pages). When you look at the front page of your site, you'll see your new post on the top, your new category in the sidebar, and the tags and category (that you chose for your post) listed under the post itself.
Images in your posts
Almost every good blog post needs an image! An image will give the reader an instant idea of what the post is about, and the image will draw people's attention as well. WordPress makes it easy to add an image to your post, control default image sizes, make minor edits to that image, and designate a featured image for your post.
Adding an image to a post
Luckily, WordPress makes adding images to your content very easy. Let's add an image to the post we just created. You can click on Edit underneath your post on the front page of your site to get there quickly. Alternatively, go back to the WP Admin, open Posts in the main menu, and then click on the post's title.
To add an image to a post, first you'll need to have that image on your computer, or know the exact URL pointing to the image if it's already online. Before you get ready to upload an image, make sure that your image is optimized for the Web. Huge files will be uploaded slowly and slow down the process of viewing your site. Just to give you a good example here, I'm using a photo of my own so I don't have to worry about any copyright issues (always make sure to use only the images that you have the right to use, copyright infringement online is a serious problem, to say the least). I know it's on the desktop of my computer. Once you have a picture on your computer and know where it is, carry out the following steps to add the photo to your blog post:
- Click on the Add Media button, which is right above the content box and below the title box:
- The box that appears allows you to do a number of different things regarding the media you want to include in your post. The most user-friendly feature here, however, is the drag-and-drop support. Just drag the image from your desktop and drop it into the center area of the page labeled as Drop files anywhere to upload.
- Immediately after dropping the image, the uploader bar will show the progress of the operation, and when it's done, you'll be able to do some final tuning up.
- The fields that are important right now are Title, Alt Text, Alignment, Link To, and Size. Title is a description for the image, Alt Text is a phrase that's going to appear instead of the image in case the file goes missing or any other problems present themselves, Alignment will tell the image whether to have text wrap around it and whether it should be right, left, or center, Link To instructs WordPress whether or not to link the image to anything (a common solution is to select None), and Size is the size of the image.
- Once you have all of the above filled out click on Insert into post. This box will disappear, and your image will show up in the post—right where your cursor was prior to clicking on the Add Media button—on the edit page itself (in the visual editor, that is. If you're using the text editor, the HTML code of the image will be displayed instead).
- Now, click on the Update button, and go and look at the front page of your site again. There's your image!
Controlling default image sizes
You may be wondering about those image sizes. What if you want bigger or smaller thumbnails? Whenever you upload an image, WordPress creates three versions of that image for you. You can set the pixel dimensions of those three versions by opening Settings in the main menu, and then clicking on Media. This takes you to the Media Settings page.
Here you can specify the size of the uploaded images for:
- Thumbnail size
- Medium size
- Large size
If you change the dimensions on this page, and click on the Save Changes button, only images you upload in the future will be affected. Images you've already uploaded to the site will have had their thumbnail, medium, and large versions created already using the old settings. It's a good idea to decide what you want your three media sizes to be early on in your site, so you can set them and have them applied to all images, right from the start.
Another thing about uploading images is the whole craze with HiDPI displays, also called Retina displays. Currently, WordPress is in a kind of a transitional phase with images and being in tune with the modern display technology; the Retina Ready functionality was introduced quite recently in WordPress 3.5. In short, if you want to make your images Retina-compatible (meaning that they look good on iPads and other devices with HiDPI screens), you should upload the images at twice the dimensions you plan to display them in. For example, if you want your image to be presented as 800 pixel wide and 600 pixel high, upload it as 1,600 pixel wide and 1,200 pixel high. WordPress will manage to display it properly anyway, and whoever visits your site from a modern device will see a high-definition version of the image. In future versions, WordPress will surely provide a more managed way of handling Retina-compatible images.
Editing an uploaded image
As of WordPress 2.9, you can now make minor edits on images you've uploaded.
In fact, every image that has been previously uploaded to WordPress can be edited. In order to do this, go to Media Library by clicking on the Media button in the main sidebar. What you'll see is a standard WordPress listing (similar to the one we saw while working with posts) presenting all media files and allowing you to edit each one.
When you click on the Edit link and then the Edit Image button on the subsequent screen, you'll enter the Edit Media section. Here, you can perform a number of operations to make your image just perfect. As it turns out, WordPress does a good enough job with simple image tuning so you don't really need expensive software such as Photoshop for this. Among the possibilities you'll find cropping, rotating, and flipping vertically and horizontally.
For example, you can use your mouse to draw a box as I have done in the preceding image. On the right, in the box marked Image Crop, you'll see the pixel dimensions of your selection. Click on the Crop icon (top left), then the Thumbnail radio button (on the right), and then Save (just below your photo). You now have a new thumbnail! Of course, you can adjust any other version of your image just by making a different selection prior to hitting the Save button.
Play around a little and you can become familiar with the details.
Designating a featured image
As of WordPress 2.9, you can designate a single image that represents your post. This is referred to as the featured image. Some themes will make use of this, and some will not. The default theme, the one we've been using, is named Twenty Thirteen, and it uses the featured image right above the post on the front page. Depending on the theme you're using, its behavior with featured images can vary, but in general, every modern theme supports them in one way or the other.
In order to set a featured image, go to the Edit Post screen. In the sidebar you'll see a box labeled Featured Image. Just click on the Set featured image link. After doing so, you'll see a pop-up window, very similar to the one we used while uploading images. Here, you can either upload a completely new image or select an existing image by clicking on it. All you have to do now is click on the Set featured image button in the bottom right corner. After completing the operation, you can finally see what your new image looks like on the front page. Also, keep in mind that WordPress uses featured images in multiple places not only the front page. And as mentioned above, much of this behavior depends on your current theme.
Using the visual editor versus text editor
WordPress comes with a visual editor, otherwise known as a WYSIWYG editor (pronounced wissy-wig, and stands for What You See Is What You Get). This is the default editor for typing and editing your posts. If you're comfortable with HTML, you may prefer to write and edit your posts using the text editor—particularly useful if you want to add special content or styling.
To switch from the rich text editor to the text editor, click on the Text tab next to the Visual tab at the top of the content box:
You'll see your post in all its raw HTML glory, and you'll get a new set of buttons that lets you quickly bold and italicize text, as well as add link code, image code, and so on.
You can make changes and swap back and forth between the tabs to see the result.
Even though the text editor allows you to use some HTML elements, it's not a fully fledged HTML support. For instance, using the <p> tags is not necessary in the text editor, as they will be stripped by default. In order to create a new paragraph in the text editor, all you have to do is press the Enter key twice. That being said, at the same time, the text editor is currently the only way to use HTML tables in WordPress (within posts and pages). You can easily place your table content inside the <table><tr><td> tags and WordPress won't alter it in any way, effectively allowing you to create the exact table you want. Another thing the text editor is most commonly used for is introducing custom HTML parameters in the <img /> and <a> tags and also custom CSS classes in other popular tags. Some content creators actually prefer working with the text editor rather than the visual editor because it gives them much more control and more certainty regarding the way their content is going to be presented on the frontend.
Lead and body
One of many interesting publishing features WordPress has to offer is the concept of the lead and the body of the post. This may sound like a strange thing, but it's actually quite simple. When you're publishing a new post, you don't necessarily want to display its whole contents right away on the front page. A much more user-friendly approach is to display only the lead, and then display the complete post under its individual URL. Achieving this in WordPress is very simple. All you have to do is use the Insert More Tag button available in the visual editor (or the more button in the text editor). Simply place your cursor exactly where you want to break your post (the text before the cursor will become the lead) and then click on the Insert More Tag button:
An alternative way of using this tag is to switch to the text editor and input the tag manually, which is <!--more-->. Both approaches produce the same result. Clicking on the main Update button will save the changes.
On the front page, most WordPress themes display such posts by presenting the lead along with a Continue reading link, and then the whole post (both the lead and the rest of the post) is displayed under the post's individual URL.
Drafts, pending articles, timestamps, and managing posts
There are four additional, simple but common, items I'd like to cover in this section: drafts, pending articles, timestamps, and managing posts.
WordPress gives you the option to save a draft of your post so that you don't have to publish it right away but can still save your work. If you've started writing a post and want to save a draft, just click on the Save Draft button at the right (in the Publish box), instead of the Publish button. Even if you don't click on the Save Draft button, WordPress will attempt to save a draft of your post for you, about once a minute. You'll see this in the area just below the content box. The text will say Saving Draft... and then show the time of the last draft saved:
At this point, after a manual save or an autosave, you can leave the Edit Post page and do other things. You'll be able to access all of your draft posts from Dashboard or from the Edit Posts page.
In essence, drafts are meant to hold your "work in progress" which means all the articles that haven't been finished yet, or haven't even been started yet, and obviously everything in between.
Pending articles is a functionality that's going to be a lot more helpful to people working with multi-author blogs, rather than single-author blogs. The thing is that in a bigger publishing structure, there are individuals responsible for different areas of the publishing process. WordPress, being a quality tool, supports such a structure by providing a way to save articles as Pending Review. In an editor-author relationship, if an editor sees a post marked as Pending Review, they know that they should have a look at it and prepare it for the final publication.
That's it for the theory, and now how to do it. While creating a new post, click on the Edit link right next to the Status: Draft label:
Right after doing so, you'll be presented with a new drop-down menu from which you can select Pending Review and then click on the OK button. Now just click on the Save as Pending button that will appear in place of the old Save Draft button, and you have a shiny new article that's pending review.
WordPress will also let you alter the timestamp of your post. This is useful if you are writing a post today that you wish you'd published yesterday, or if you're writing a post in advance and don't want it to show up until the right day. By default, the timestamp will be set to the moment you publish your post. To change it, just find the Publish box, and click on the Edit link (next to the calendar icon and Publish immediately), and fields will show up with the current date and time for you to change:
Change the details, click on the OK button, and then click on Publish to publish your post (or save a draft).
If you want to see a list of your posts so that you can easily skim and manage them, you just need to go to the Edit Post page in the WP Admin and navigate to Posts in the main menu. Once you do so, there are many things you can do on this page as with every management page in the WP Admin.
Advanced post options
By now, you have a handle on the most common and simple options for posts, and you may be wondering about some of the other options on the Edit Post page. We'll cover them all in this section.
When you first visit the Edit Post page, some of the advanced options (Excerpt, Send Trackbacks, Custom Fields, Discussion, Revisions, Author, and Format) are "open" below the post content. If you never use them and want to clean up the look of this page, you can single-click each bar and they'll collapse. You can also rearrange them by dragging them to form a new order.
You can also use Screen Options (top right of the page) to uncheck certain boxes, and thus not display them at all.
WordPress offers theme designers the option to show a post's excerpt (instead of its full content) on pages within the theme.
This is how the excerpt works:
- If you enter some text into the excerpt box on the Edit Post page, that text will be used as the post's excerpt on theme pages that call for it
- If you do not enter any text into the excerpt box, WordPress will use the first 55 words of the post's content (which is stripped of HTML tags) followed by […] (which is not a link)
- If you do not enter any text into the excerpt box, and the theme you are using does something special, the number of words and the final text could be different
You are never required to enter excerpt text. However, it is advisable that you do take advantage of this possibility. Excerpts can introduce big readability improvements to your site and make your content easier to grasp for the reader, provided that your current theme uses excerpts in one way or the other.
The more tag (<!-- more -->), which has been described in one of the previous sections in this article, should not be confused with the excerpt. It is different from the excerpt because you, not the theme designer, control its use. Additionally, the more tag is supported by every theme and has a slightly different task than the excerpt. It's meant to present the lead of the post, the part that's going to convince the reader to visit the complete post, while the excerpt is a summary of the post's contents.
Sending pingbacks and trackbacks
Pingbacks and trackbacks provide you with a way to communicate with other websites, and let them know that you've published a post mentioning them in one way or the other (usually through a link). For instance, they are useful if you write a blog post that is a response to an old post on someone else's blog and you want them to know about it.
The difference between pingbacks and trackbacks is that pingbacks are automatic whereas trackbacks are manual. In other words, WordPress always tries to send a pingback automatically whenever you link to another WordPress blog from any of your posts. Trackbacks are something you have to send manually, as WordPress will not do this for you. Apart from that, pingbacks and trackbacks are pretty much the same and produce a very similar effect.
If you want to notify a given blog via trackback, just copy the trackback URL from that person's blog post and paste it into the trackback box on your post's editing screen. An excerpt of your blog post and a link pointing back to your site will show up as a comment on their blog post, provided that the blog has trackbacks enabled. Sending an automatic pingback will also include a link pointing back to your site in the comments section. Again, that is if the blog you're targeting has trackbacks and pingbacks enabled.
Quite frankly, trackbacks are becoming somewhat out of date with the advent of pinging. Many WordPress themes are written to essentially disable trackbacks. As it turns out, most WordPress bloggers these days don't even bother to send trackbacks when the built-in mechanism of pingbacks handles it automatically.
The Discussion box on the post editing screen has two checkboxes in it: one for allowing comments, and the other for trackbacks and pingbacks. When you first install WordPress, both these checkboxes will be checked by default. You have to uncheck them if you want to turn off the comments or trackbacks and pingbacks for the post.
If you uncheck the Allow comments box, visitors will not be able to comment on this blog post.
If you uncheck the Allow trackbacks and pingbacks on this page box, when other people mention your blog post and link to it on their own websites, your blog post won't notice and won't care. So, if you are using WordPress to run a non-blog website, this is the best option for you.
If the box stays checked, other people's pingbacks about this post will show up under your post along with comments, if any. If you're using WordPress to run a blog website, you'll want pingback to stay checked, especially if you want sites such as Technorati and other rating/authority sites to stay alerted.
If you want either or both of these boxes to be unchecked by default, go to Settings and then Discussion in the main menu. You can uncheck either or both of the boxes labeled Allow link notifications from other blogs (pingbacks and trackbacks) and Allow people to post comments on new articles.
The decision whether or not to support trackbacks and pingbacks on your site is entirely up to you. Even though they are both enabled by default, some bloggers quickly find that disabling them can make their everyday work much easier. The thing with pingbacks and trackbacks is that a large number of them, especially on popular blogs, are essentially spam. Basically, pingbacks and trackbacks are (were) the easiest way of getting a link from another site. Back in the day, no one was paying attention to what appeared in their pingback and trackback section, so every notification went through un-moderated in any way. These days, despite the fact that online publishers are much more aware of the situation, the spamming continues and it gets difficult to separate genuine pingbacks and trackbacks from the spammy ones. Hence, shutting them down altogether can make things easier in the long run.
To learn more about trackbacks and pingbacks you can visit the following sites:
Custom Fields are WordPress' way of giving you the possibility to include some additional information in your blog post (information that you don't want to display directly on the frontend). In essence, Custom Fields are a kind of a semi-programming tool—they are not exactly "code" as understood by PHP programmers, yet they do give you a possibility to tweak your content in a certain, non-stock way. Many themes use various Custom Fields to style the individual aspects of posts. For example, some theme creators use Custom Fields to disable the sidebar on certain posts or include various typographic elements.
Another example, let's say you are a gadget reviewer and every blog post is a review of some new gadget. Every time you write a review, you're writing it about a product made by some company, and you'd like to have that company's logo associated with the blog post. You can make a custom field called company_logo and the value can be the path to the logo image.
To display or make use of this custom field information, you either have to modify your theme files manually, or use a plugin.
Read more about Custom Fields in the WordPress codex at http://codex.wordpress.org/Using_Custom_Fields.
Working with post revisions
Apart from many content formatting features, WordPress also allows some basic version control for your posts. What this means is that WordPress stores every subversion of your every post. Or in plain English, every time you click on the Update button, instead of overwriting the previous version of your post, WordPress creates a completely new one. Although this feature doesn't seem like the most useful one at first, it's actually very important for sites where the content is managed by more than one person. In such a scenario, it's easy to get the newest versions of the posts mixed up, so it's always good to have the possibility to return to the previous one.
In WordPress 3.6, the Revisions functionality has been completely revamped and a lot of new features have been introduced that make working with your content much more efficient. To take full advantage of the functionality, what you need to do is, first, enable Revisions in the upper slide-down Screen Options menu on the post editing screen. Once you do so, a small boxed titled Revisions will appear at the bottom of the screen.
If you click on any of the links displayed inside this box, you will be taken to a page where you can compare individual revisions and then restore the one you want to work with from now on. The interface provides a main slider that can be used to select individual revisions of the post as shown in the following screenshot:
The revision functionality has two main versions. The first one, when the Compare any two revisions box isn't checked, lets you compare the revision that's currently selected (on the slider) to the revision directly preceding it. The second version is when the Compare any two revisions box is checked. In this case, you can select the revisions you want to compare individually, which allows you to essentially compare any two revisions just like the box suggests. The revision on the left is always the previous revision, while the one on the right is the next or current one (visible in the preceding screenshot). Every paragraph where there is a difference found will be highlighted in red and green, and every individual difference will have additional highlighting. Clicking on the Restore This Revision button will restore the revision on the right and you will be brought back to the post editing screen automatically.
On the other hand, if you feel that revisions won't be of any particular use to your site, you can simply not pay attention to the Revisions box. When you work with your content normally, not worrying about the revisions, WordPress will always display the most recent versions of your posts by default.
Changing the author of the post
This is a very basic feature in WordPress so let's only take a minute to discuss it. Basically, every post and page in WordPress has an author, which is quite obvious in itself. However, if you want to, you can change the assigned author of any given entry. In order to do it, just go to the post editing screen or the page editing screen and scroll down until you see the Author box. (If it's not visible, enable it from the pull-down Screen Options menu).
The box contains just one drop-down menu that lists every user account on your site. Just select a new author and click on the Update button. That's all. If you only have one user, the admin account, on your site, the box will contain one name.
WordPress gives you the option to hide posts. You can hide a post from everyone but yourself by marking it Private (although the user roles of admin and editor will still see it), or you can hide it from everyone but the people with whom you share a password by marking it as Password protected. To implement this, look at the Publish box at the upper right of the Edit Post page. If you click on the Edit link next to Visibility: Public, a few options will appear:
If you click on the Password protected radio button, you'll get a box where you can type a password. Visitors to your blog will see the post title along with a note that they have to type in a password to read the post.
If you click on the Private radio button, the post will not show up on the blog at all to any viewers, unless you are the viewer and you are logged in. The post will also appear if the person browsing the site is a logged-in editor (having the user role of Editor).
If you leave the post Public and check the Stick this post to the front page checkbox, this post will be the first post on the front page, regardless of its publication date.
Be sure to click on the OK button if you make any changes.
The pretty post slug
Let's discuss a little about something called the post slug. One of the most accurate definitions in existence of what a post slug is comes from the WordPress codex itself. The one provided at http://codex.wordpress.org/Glossary#Post_Slug teaches us that the post slug is:
A few lowercase words separated by dashes, describing a post and usually derived from the post title to create a user-friendly permalink.
In other words, the post slug is what comes after your domain name in the post's URL. For example, my post about Making Lasagne uses this URL: http://mydomain.com/making-lasagne/, where the last part, making-lasagne, is the slug. Just like the official definition says, WordPress chooses the slug by taking my post title, making it all lowercase, removing all punctuation, and replacing spaces with dashes. If I'd prefer it to be something else, such as my-lasagne, I can change it in the area just below the post's title:
Just click on Edit to change the slug. Readable URLs are something that Google search loves, so using them helps to optimize your site for search engines. It also helps users figure out what a post is about before clicking on the URL.
Custom post format settings
Since you will most likely start your WordPress journey with the default theme, Twenty Thirteen, I should probably say a few words about one more box that's visible on the post editing screen, the one titled Format.
This article describes various ways in which you can create posts on blogs with the help of different options. These options define various fields, tags, settings, and so on, which act as a detailed guide to help you create posts on a WordPress blog.
Resources for Article:
- Introduction to a WordPress application's frontend [Article]
- Customizing WordPress Settings for SEO [Article]
- FAQs on WordPress 3 [Article]