Automating the If Then with IFTTT

IFTTT stands for If This Then That. It is a way to automate a basic If statement to connect blogs, rss feeds, and social media. Above is an image of an active IFTTT recipe. In it If a new post comes out on the Complete Developer Podcast (a new episode) it will automatically post to my blog so those of you following me but not the podcast will have a chance to see when new episodes are posted.

It uses API (Application Program Interface) to check and see IF there is a new post THEN it uses the social media API like Twitter’s REST to post. There are a total of 220 channels to pull from in the IF section and push to in the THEN section. Each of the channels has options specific to its media form like posting a link or an excerpt from a blog, adding a picture, or specifications for when and what to post.

For example, I have IFTTT setup to post my blog posts to the Complete Developer Podcast site and set up to post of my blog from there when new episodes come out. IFTTT has an option to only post from my blog when it contains certain labels. This way I am able to avoid creating a posting loop when new episodes come out.

Also, I can disable a recipe (If/Then statement) without having to delete it. This way if I’m going to be on vacation and don’t want the photos I post on Facebook to flood my other media I can turn that off so that when I return I don’t have to go through the process of setting it up again. Below is an image of a recipe that has been turned off.

With IFTTT you can set up some interesting automations. Here are a few tricks I’ve picked up in the past couple of days working on the Complete Developer Podcast website as well as my own blog.

Currently I have a setup so that post from here will show up only on the Blogs page of the Complete Developer Podcast. I did this by setting IFTTT to only pull posts with the label WordPress from my blog here on Blogger. This allows me to have IFTTT post to my blog from our WordPress site without worry about redundant posts. I then set the IFTTT THEN section to post to WordPress in the category Blog. Using the List Category Posts plugin I created a blank page with the title Blogs then placed the short code for the Blog category so that only the posts in that category will show up in the feed.

I used a few more of the short codes to allow for use of custom CSS and set the parameters that I wanted for the page. I was even able to match the title covers to the hex code of the color on our logo.

With this I added the Ultimate Category Excluder plugin to remove the posts in category Blog from search results and SEO (search engine optimization) as well as the Recent Posts feed. This way our blogs only show up in the Blog section in addition to our own personal sites.

This was great, except the first time I used it I typed “Wordpress” in the Labels field on Blogger instead of “WordPress”. Because of this error IFTTT did not pull the post from Blogger. Also, if listing multiple Labels put WordPress at the end as comma may interfere with IFTTT. To promote my own laziness and forgetfulness I went ahead and created separate recipes for each of the ways I could type out “wordpress”. I then did this for my social media recipes.