Pinterest RSS Widget – A WordPress Plugin To Display Your Latest Pins
Downloaded 59734 times!
I am extremely proud and pleased to share with you a new WordPress plugin created by bkmacdaddy designs called Pinterest RSS Widget. It’s a handy little plugin for WordPress users who are also using the latest social sharing sensation called Pinterest. You can use this free plugin to display up to 25 thumbnails of your latest Pinterest Pins in your sidebar or anywhere else in your WordPress theme that uses widgets. You can also use it without a widget by either using template tags in your theme files or using the shortcode in your posts or pages. It’s easy to install and configure to match your theme’s design, and it has several options that will help you encourage your visitors to connect with you on Pinterest.
You can download the plugin from the WordPress Plugin Repository HERE, or you can install it automatically from your WordPress dashboard. Simply search the plugins for “Pinterest” and you’ll find it at or near the top of the list. If you find the plugin useful, please consider donating to encourage the further support and improvement of this and other plugins from bkmacdaddy designs.
What you can do with the Pinterest RSS Widget WordPress plugin
- Show thumbnails of your latest pins.
- Choose whether or not show the first few words of the title of each pin beneath it.
- Choose how many thumbnails to show, from 1-25.
- Set the height and width of all thumbnails.
- Set each Pin’s link to open in the same or a new window/tab.
- Choose whether or not to show a “Follow Me On Pinterest” button below the thumbnails, linked to your account.
How to use the Pinterest RSS Widget WordPress plugin
Installation is done the usual way. You can either download the plugin from the WordPress Plugin Repository and upload it via FTP or use the built-in WordPress plugin installer, or you can install it directly from within the WordPress Administration Dashboard Plugins area.
Once installed and activated, you simply navigate to the Appearance > Widgets area and drag and drop the Pinterest RSS Widget to the sidebar where you want it to appear. Once you drop it in the sidebar you are presented with a number of options as follows:
- Title: enter the title of the widget as you want it to appear in your sidebar.
- Pinterest Username: enter the username of the Pinterest account you wish to display Pins from.
- Max number of pins to display: enter any number from 1-25. It’s best to figure out the size of the thumbnails and how many will fit in a row or rows within your sidebar. You may need to play with this option a little to see what works best for your theme.
- Thumbnail Height in pixels: enter the height of each thumbnail as best fits your sidebar and theme. This measurement is in pixels and defaults to 150. You only need to enter the number and not the ‘px’ that follows in CSS.
- Thumbnail Width in pixels: enter the width of each thumbnail as best fits your sidebar and theme. Just like the height, this measurement is in pixels and defaults to 150, and you only need to enter the number.
- Where to open the links: select either “New Window” or “Same Window” from the dropdown to choose where you want the Pins to open when clicked on. New Window is better for keeping visitors on your site.
- Display title below pins? Selecting “Yes” will show the first few words of each Pins title/description directly beneath its thumbnail. Selecting “No” will, of course, not show the text.
- Show “Follow Me On Pinterest” button: select “Yes” to show the official red “Follow Me On Pinterest” button below the whole group of thumbnails. The button is automatically linked to your Pinterest account and will take the visitor there to follow you. Select “No” to refrain from showing the button.
- Use RSS enclosures? This should be left at “Yes” for most websites.
Click the blue button labeled “Save” and you’re good to go!
How to use the Pinterest RSS Widget WordPress plugin in your theme (not as a widget) with template tags
The plugin also works well outside of the widget usage, so if you’re a theme developer or someone who knows their way around enough to mess with the code, you can display the list of latest Pins thumbnails by placing the following code in your theme files where you want them to appear:
<?php get_pins_feed_list($username, $maxfeeds, $divname, $printtext, $target, $useenclosures, $thumbwidth, $thumbheight, $showfollow); ?>
Here are the variables and how to use them:
- username is the Pinterest username you wish to display Pins from (mandatory)
- maxfeeds is the maximum number of Pins to display (optional, default = 25)
- divname is a name suffix for the list class. “myList” will become “pins-feed-myList” (optional)
- printtext must be 1 if you want the image title/description to show below the image (optional)
- target is “samewindow” or “newwindow”, depending on where you want links to open (optional, default = samewindow)
- useenclosures is “yes” or “no” (optional, default = yes). Use this if you don’t want to use the tag in the feed and force the script to find an image link in the feed item description.
- thumbwidth is a number that will set the width in pixels of the Pin’s thumbnail (optional, default = 150)
- thumbheight is a number that will set the height in pixels of the Pin’s thumbnail (optional, default = 150)
- showfollow is “yes” or “no” (optional, default = yes). Use this if you want to show the “Follow Me On Pinterest” button below the thumbnails.
Here’s an example:
<?php get_pins_feed_list('bkmacdaddy', 10, 'myList', 1, 'newwindow', 'yes', 125, 125, 'yes'); ?>
The code above will display ten 150×150 pixel thumbnails/Pins from my bkmacdaddy Pinterest account with each list item using the CSS class “pins-feed-myList”. When clicked on, the pin will open in a new window or tab. The “Follow Me On Pinterest” button will display beneath the entire list of thumbnails. Here’s an example of how it can look in a footer:
How to use the Pinterest RSS Widget WordPress plugin in your posts and pages with the shortcode
You can also use the plugin’s shortcode to display your latest pins in posts or pages. While editing the post or page that you want to add your Pins to, enter the shortcode [prw username=“Your Pinterest Username”]. At the very minimum you have to include the username parameter, substituting “Your Pinterest Username” with your actual Pinterest username. The rest of the parameters are the same as listed above in the template tags explanation, and the defaults are also the same. Here’s an example::
[prw username="bkmacdaddy" maxfeeds="10" divname="myList" printtext="0" target="newwindow" useenclosures="yes" thumbwidth="100" thumbheight="100" showfollow="medium"]
The above example will show the 10 latest Pins from my (bkmacdaddy) Pinterest account, in a div class titled “pins-feed-myList”. Each thumbnail will be 100 x 100 pixels with no description below them. When clicked on, the Pin will open in a new tab/window, and the Follow Me On Pinterest button at the bottom will be the medium sized one.
If you leave out any of the parameters they will revert to the defaults listed in the template tags explanation above.
If your images are not showing, here are some of the possible reasons
There are so many variables that are related to hosting servers and such that it’s impossible to provide all of the possible answers. However, images not showing is most likely a problem with the timthumb.php image resizing script that is included in the plugin. Here are some possible solutions:
- TimThumb requires the GD library, which is available on any host sever with PHP 4.3+ installed. Make sure your host has this installed (most do).
- Once installed and in-use, TimThumb will automatically create a /prw_tmp/ subfolder in your/ wp-content/uploads/ directory with proper write-permissions. If your host server doesn’t allow this by default, be sure to manually create the /prw_tmp/ subfolder in your/ wp-content/uploads/ directory and set the /prw_tmp/ folder permissions to 755. If this still doesn’t work, try setting the /cache/ folder permissions to 777.
- Known issue with timthumb.php on Hostgator: If your website is hosted on Hostgator, you may need to contact HostGator to request “mod_security whitelisting”. More info here: http://support.hostgator.com/articles/specialized-help/technical/timthumb-basics
If for some strange reason you’re still having issues, please use the WordPress support forum for the plugin or send me a message via my contact form or on Twitter to @bkmacdaddy and I will do everything I can to help you get it working.
Acknowledgements and thank-yous
This was my first journey into the world of WordPress plugin development, and I could not have possibly succeeded without the assistance and brilliance of the following:
- Yorik van Havre, who created the Image Feed Widget plugin that became the basis for this one. His code made it much easier for me to get my feet wet and figure this thing out.
- Aida B. (Aida of Nubia), who first brought the need for this plugin to my attention and then proceeded to help me test and improve it. Connect with her on Pinterest or at her website.
- Dee Teal, who offered great suggestions, helped clean up the code and tested and tweaked the plugin with Aida and me. Connect with her on Pinterest or at her website.
Let me know how the plugin works for you
Please be sure to leave a comment below letting us know how you fare with the plugin, along with a link to where you’re using it. If you really love it, please consider a donation for the time spent developing and supporting it. At the very least, please submit your star rating of the plugin on its WordPress Repository page. Oh, and you can connect with me on Pinterest here. Enjoy!