Avoiding AddThis in a WordPress Post or Page

Since social networking is very important, we leverage the AddThis WordPress plug-in to allow visitors to share pretty much anything, page, post, index, archive, etcetera. However, there are some cases where it really makes no sense (e.g. our Search page) or it conflicts with another bit of technology (e.g. our Contact Us page leverages our theme’s built in contact template, and their interaction causes the AddThis icons to show up in the middle). I figured there must be a custom WordPress field that could turn it off, but could not find docs on the AddThis web site or on the plug-in page.

A little code surfing later I figured out (and then confirmed in real life) if you add “addthis_exclude” as a custom field and set the value to “true” (that word literally…without the quotes) the page or post you add it to will not show the AddThis icons.

There is a solution…

Comments are closed.

line
footer
Powered by WordPress | Designed by Elegant Themes