Products Under Post: One Solution for Holiday Sales

Products for Sale on Frugal for Everyone - products under post
An example of showing products under post

Have you ever wanted something to appear on your blog, and you cannot quite figure out how to do so using the usual editing tools that WordPress provides? Do you have products or services you would like to highlight? Do you have a particular message you want to show up in a certain way under each post, and none of the plugins that you have examined seem quite what you need?

Lenie of Frugal for Everyone contacted me early this fall and asked if I could help her display her Etsy products under each post. What I did was I wrote a small plugin specific for her needs. I will talk about the plugin in general, and then I will provide a few more of the technical details (so if the technical part is too much, feel free to skip it).

Display Products Under Post – Overview

The idea was that at the end of a post, on top of the comment area, one should be able to see a thumbnail, description and title of a certain product. If you are already using an e-commerce solution like WooCommerce there are plugins to do this. However, in this case the products are on an Etsy Shop. What was needed was quite simple: a custom content type for the products and some code to display them under each post.

A section for these Products was added to the back end left column. The client just needs to go in and add a new product, adding featured image for the thumbnail, description in the body and a title. Custom fields for price and for the Etsy link were added as well. Editing a product is as simple as editing a page or post. If a product is no longer needed, it can be deleted. To keep a product in the back end but have it not display, one simply changes the status to draft.

Add New Product

Display Products Under Post – Technical Details

If you want to do something similar on your blog and you are comfortable with coding, this is not too hard a project. The first part would be to set up a custom content type. You can use a plugin called CPT UI to help you do this. There are also tools to help generate code for a custom content type. I would highly recommend putting all the code in a plugin and separate the whole thing from the theme. So, yes, you need to know how to create a simple plugin. Finally, you need to be able to display the custom content type. I wrote a plugin that basically tacks the products at the end of the ‘the_content’. How the products look is controlled with CSS.

Projects for Your Own Blog

Sometimes you may say: I want something to appear automatically over here. You search for a plugin, but whatever you find doesn’t do quite what you need. It might be complicated for a developer to put together, or it may not. In this case, it was something I enjoyed creating and did not take a lot of work on my part, as I have lots of experience with coding. But I’ve heard of some ideas that I would not touch with a ten foot pole.

Over to You

Have you ever had custom coding work done for your blog or website? Did it work out well or did it not? Is there anything you would be curious could be done on your own site? If you have visited Frugal for Everyone, did you notice the products under the posts?

Please share:Pin on PinterestTweet about this on TwitterShare on FacebookShare on Google+Share on LinkedIn

22 thoughts on “Products Under Post: One Solution for Holiday Sales

  1. Leora, as you know I am so very pleased with the ‘products under post’ plugin you did for my site. I am totally non-techie yet find it easy to use and navigate. I also appreciated the quick response to all my ‘little’ questions.
    Now to your site here – I love those bars you have for your paragraph titles – maybe something to discuss next year.
    -Lenie

    1. Lenie,

      I had a lot of fun working on your products. As to the bars for paragraph (actually, for section) titles: maybe I will write a post on that topic. It is not hard to do – just a little CSS (so if client doesn’t feel comfortable adding CSS, it should not be hard at all for a web developer to do so – fairly basic).

  2. This looks terrific Leora. I know absolutely zilch about coding, in fact whenever directions to something include that word it makes my eye twitch. So far I haven’t had occasion to hire someone to do custom coding, but if I ever find myself needing that type of work done you can bet I’ll pay someone before attempting it myself. Thanks for the insights and inspiration!
    Marquita Herald recently posted…Simple Ways to Give a Gift of Kindness This HolidayMy Profile

  3. I know very little about plug ins so thank you.

    I host my blog with WordPress and learn something new each day. I am always trying to find ways to improve and develop my blog.

  4. Hi Leora

    Great job on Lenies site listing her products under post. Looks great. Afraid I’m more apt to have my computer guy David handle this for me too and stick to what I’m best at. ☺ for you tech savvy folks I’m sure it’s a breeze!

  5. That’s great that you were able to develop a plugin that fit Lenie’s needs perfectly. I too can attest to your work back from quite a while ago that you helped me switch my hosting from GoDaddy to BlueHost. I have such a long list of things I would love to do on my site, but unfortunately a very empty pocketbook these days 😉

  6. Leora — so glad you could help Lenie. That’s the beauty of our blogging community as I know there have been other collaborations among members, too. I’m like Marquita — my eye twitches even thinking about coding. I leave that to the experts like you.

Please leave a comment.

Your email address will not be published. Required fields are marked *

CommentLuv badge