The Power User Guide to the Better Click To Tweet WordPress Plugin

This is the guide to the hidden features of the Better Click To Tweet WordPress plugin. To start with, here’s a bit of philosophy. (If you want to get straight to the how-to, skip to the appropriate sections below)

Why Hide the Power Features?

WordPress is a fantastic tool for publishing. The low entry bar and “5 minute install” have made it such that you can set your grandfather up with a self-hosted website that he can update and love.

I always have your grandfather in mind when I am developing my plugins. I want to go out of my way not to do something that would lose him. The WordPress philosophy calls this “Decisions, not Options.”:

As developers we sometimes feel that providing options for everything is a good thing, you can never have too many choices, right? Ultimately these choices end up being technical ones, choices that the average end user has no interest in. It’s our duty as developers to make smart design decisions and avoid putting the weight of technical choices on our end users.

I debated whether even adding the option to remove the via was giving too many options. But I had multiple users asking for that functionality, so I added it in as a visible option.

It turns out the Internet is a picky place, and requests for very specialized functionality started rolling in. This guide is for those power users. Here’s to making power users happy while not alienating your grandpa.

So, instead of making visible options (which violates the spirit of the WordPress philosophy), I made each of the following features an invisible one: you have to know they’re there to utilize them. There’s no checkbox or dropdown menu.

Selectively Removing the URL

A few users have asked for the ability to remove the URL from the tweet. The vast majority of my plugin’s users want a link back to the post when they create a click to tweet box, but for those who don’t, now there’s a way to remove that link.

This is such a life-changing quote it doesn't need a link. Share on XIf you want to remove the URL linking back to your post from a tweet, simply modify the shortcode, adding a new parameter of url="no". So, to make a box that looks and behaves like the quote to the left. (click the text to see that there’s no URL in the resulting tweet)

Your shortcode would look like this:

[bctt tweet="This is such a life-changing quote it doesn't need a link." url="no"]

If you additionally wanted to remove the “via” the shortcode would be:

[bctt tweet="This is such a life-changing quote it doesn't need a link." url="no" via="no"]

UPDATE: as of version 4.2, now you can input a custom URL in the url parameter, and the custom url (no matter how long) will be passed on to the tweet. So, this shortcode will link to the fictitious page “http://yourwebsite.com/you-can-even-use-long-urls-here”:

[bctt tweet="This tweet will contain a totally custom URL" url="http://yourwebsite.com/you-can-even-use-long-urls-here"]

Have you checked out the best Click To Tweet plugin for WordPress? Share on X This is helpful for click to tweet boxes that you want to use to link to other things, like products. For example, I could use it to promote my plugins from within a blog post, like the quote to the left.

Known issues:

  • URLs with non-ascii characters (éåø and the like) are not currently supported. This is a limitation of PHP, and something I’m working to fix in a future release.
  • You must include the http:// or https:// at the beginning of the url parameter.
  • If your URL has the & symbol in it, it’ll confuse Twitter, and things will go badly. To avoid this issue, manually shorten your custom URLs that have that symbol in them using a service like bit.ly before inserting it in the shortcode.

Selectively making links “nofollow”

If you, like me, have only a vague idea of what the concept of “nofollow” is in the SEO world, this infographic might help.

Making the front-facing links in your Better Click To Tweet boxes “nofollow” probably has very little effect on your SEO, but some folks pay a lot of attention to such things, and started to request on the forum that I enable rel="nofollow" on the links generated on posts by my plugin.

As of version 4.0, adding the nofollow attribute in the Better Click To Tweet box is as simple as adding an extra nofollow="yes" attribute to the shortcode:

[bctt tweet="Dear Search Engines, Please don't follow this link." nofollow="yes"]

Designing Custom Templates

Do you love the Better Click To Tweet plugin, but aren’t super jazzed by the design of the boxes?

As of version 4.1, there’s an option to completely take control of the design of the boxes on the front end of the site.

Here’s a step-by-step on how to make that happen.

  1. Connect via FTP to your site’s server.
  2. Drag the bcttstyle.css file currently in /wp-content/plugins/better-click-to-tweet/assets/css to the root of your /wp-content/uploads directory
  3. Poof. Done. Your box style just completely changed, and you haven’t touched any code.
Just drag it, drop it, and go refresh your site!

Any changes you make to the bcttstyle.css file will be reflected on your site. If you don’t like the new style, you can change it back by moving, renaming, or deleting the file in your /uploads directory. Also, the fact that the new file lives in the root of your /uploads directory means that any changes you make to it will not be overwritten by future plugin updates!

*note* If you come up with some cool designs, feel free to let me know, and they can be included in the plugin as options in future releases. I’ll credit you here and on the official WordPress.org repository page.

I’ll continue to update this post in the event that more advanced features are added to the plugin. Here’s to making the web a less confusing space for your Grandpa, but a more powerful place for you.

Speaking of my services (wait, did I forget to mention I offer WordPress services?) I specialize in outrunning and outsmarting hackers. Contact me today to get started.

I’ve closed comments on this post. If you need support, please use the official plugin support forums.

9 Replies to “The Power User Guide to the Better Click To Tweet WordPress Plugin”

  1. Your plugin is fantastic & really every blogger should use it! The click to tweet option makes blogs look more visually interesting and is bound to improve visitor interaction and social sharing. This guide of advanced options makes me even happier with your plugin.

    Thanks!

  2. Hi Ben,

    thank you for your very good work! I’ve one question: Is it possible to set it right or left beneath and floating to the text or is it just possible to set it fullwidth? This would be very awesome!

    Thanks for your reply
    Tobi

  3. Can you let me know how to make the click to open in a window like a modal? I see other sites open a detached window for FB and Twitter. Yours just opens a new tab for me (chrome).

    And While I have you can you tell me if its possible to do the same functionality for Facebook – Everything I can find shares the whole page not just a custom phrase like yours.

    1. Hey Chris,

      I remember when I was first developing the plugin looking into the modal thing, and decided not to add any extra js to the plugin itself. https://dev.twitter.com/web/intents has a great run-down if you are up to the challenge. It may be as simple as adding in the call to platform.twitter.com/widgets.js somewhere in the footer of your site. If I get some time, I may look into that and do some testing to see how it effects load time and performance.

      And regarding facebook, I am not as familiar with their API, so I’d have to look around. Twitter makes it suuper easy for developers. I just haven’t looked at FB.

      Thanks for taking the time to comment (and for using my plugin!)

Comments are closed.