Better Click To Tweet - Version 4.8

Version Description

  • made span classes filterable, so that other developers don't hate me when they try to extend the plugin.
  • I know that first point doesn't sound like much, but it's huge for developer geeks. You're just gonna have to trust me.
  • removed the names of translators from the "description" since they are now being handled by official language packs, and giving credit where it is due was getting complicated.
Download this release

Release Info

Developer ben.meredith@gmail.com
Plugin Icon 128x128 Better Click To Tweet
Version 4.8
Comparing to
See all releases

Code changes from version 4.7.1 to 4.8

Files changed (2) hide show
  1. better-click-to-tweet.php +6 -2
  2. readme.txt +8 -11
better-click-to-tweet.php CHANGED
@@ -2,7 +2,7 @@
2
/*
3
Plugin Name: Better Click To Tweet
4
Description: Add Click to Tweet boxes simply and elegantly to your posts or pages. All the features of a premium plugin, for FREE!
5
- Version: 4.7.1
6
Author: Ben Meredith
7
Author URI: https://www.wpsteward.com
8
Plugin URI: https://wordpress.org/plugins/better-click-to-tweet/
@@ -175,9 +175,13 @@ function bctt_shortcode( $atts ) {
175
176
}
177
178
if ( ! is_feed() ) {
179
180
- return "<span class='bctt-click-to-tweet'><span class='bctt-ctt-text'><a href='https://twitter.com/intent/tweet?text=" . rawurlencode( html_entity_decode( $short ) ) . $handle_code . $bcttURL . "' target='_blank'" . $rel . ">" . $short . " </a></span><a href='https://twitter.com/intent/tweet?text=" . rawurlencode( html_entity_decode( $short ) ) . $handle_code . $bcttURL . "' target='_blank' class='bctt-ctt-btn'" . $rel . ">" . $bcttBttn . "</a></span>";
181
} else {
182
183
return "<hr /><p><em>" . $short . "</em><br /><a href='https://twitter.com/intent/tweet?text=" . rawurlencode( html_entity_decode( $short ) ) . $handle_code . $bcttURL . "' target='_blank' class='bctt-ctt-btn'" . $rel . ">" . $bcttBttn . "</a><br /><hr />";
2
/*
3
Plugin Name: Better Click To Tweet
4
Description: Add Click to Tweet boxes simply and elegantly to your posts or pages. All the features of a premium plugin, for FREE!
5
+ Version: 4.8
6
Author: Ben Meredith
7
Author URI: https://www.wpsteward.com
8
Plugin URI: https://wordpress.org/plugins/better-click-to-tweet/
175
176
}
177
178
+ $bctt_span_class = apply_filters( 'bctt_span_class', 'bctt-click-to-tweet' );
179
+ $bctt_text_span_class = apply_filters( 'bctt_text_span_class', 'bctt-ctt-text');
180
+ $bctt_button_span_class = apply_filters('bctt_button_span_class', 'bctt-ctt-btn');
181
+
182
if ( ! is_feed() ) {
183
184
+ return "<span class='" . $bctt_span_class . "'><span class='" . $bctt_text_span_class . "'><a href='https://twitter.com/intent/tweet?text=" . rawurlencode( html_entity_decode( $short ) ) . $handle_code . $bcttURL . "' target='_blank'" . $rel . ">" . $short . " </a></span><a href='https://twitter.com/intent/tweet?text=" . rawurlencode( html_entity_decode( $short ) ) . $handle_code . $bcttURL . "' target='_blank' class='" . $bctt_button_span_class ."'" . $rel . ">" . $bcttBttn . "</a></span>";
185
} else {
186
187
return "<hr /><p><em>" . $short . "</em><br /><a href='https://twitter.com/intent/tweet?text=" . rawurlencode( html_entity_decode( $short ) ) . $handle_code . $bcttURL . "' target='_blank' class='bctt-ctt-btn'" . $rel . ">" . $bcttBttn . "</a><br /><hr />";
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.wpsteward.com/donations/plugin-support/
4
Tags: click to tweet, twitter, tweet,
5
Requires at least: 3.8
6
Tested up to: 4.6
7
- Stable tag: 4.7.1
8
License: GPLv2 or later
9
License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
@@ -25,19 +25,11 @@ This plugin allows you to easily create tweetable content for your readers. Usin
25
>This plugin started as a complete retool of the "Click To Tweet" plugin by Todaymade. In addition to the user-focused changes above, the under-the-hood changes include correct character counting when dealing with non-Roman characters, translation-readiness, and use of the official shortcode API (which means security and forward-compatibility)
26
27
28
- **Speaking of the area under the hood:** developers, please hop in and suggest improvements. You can submit pull requests at the [github repo](https://github.com/Benunc/better-click-to-tweet "plugin github repo") for this plugin. I'm also actively seeking translators to bring the usefulness of this plugin to non-English speakers. Please message me in the forums.
29
30
Huge thanks to Andrew Norcross @norcross for the help with making the plugin even better as of v4.0 with enhancements to the Visual Editor's button. But you can't blame him for any of the other code!
31
32
- Translators:
33
-
34
- * EspaƱol (es_ES): Jordi Rosalez
35
- * Serbian (sr_RS): [Borisa Djuraskovic](http://www.webhostinghub.com/ "Web Hosting Hub")
36
- * Finnish/Suomi (fi): [Sampsa Daavitsainen](http://www.calltoaction.fi/ "CallToAction.fi")
37
- * Russian (ru_RU): webbolt
38
- * Swedish (sv_SE): [Stefan Nilsson](http://www.stefannilsson.nu/ "Stefannilsson.nu")
39
- * German (de_DE): [Christian Zumbrunnen](http://chruezundquer.ch/ "chruezundquer.ch")
40
- * Italian (it_IT): [Luca at MoweCode](http://www.mowecode.com/ "www.mowecode.com")
41
42
== Installation ==
43
@@ -109,6 +101,11 @@ I want to maximize the usefulness of this plugin by translating it into multiple
109
110
== Changelog ==
111
112
= 4.7.1 =
113
* updated links throughout the back end of the plugin to send me money, for people who are into that sort of thing. Shoutout to https://givewp.com for the SWEET donation integration on my site.
114
4
Tags: click to tweet, twitter, tweet,
5
Requires at least: 3.8
6
Tested up to: 4.6
7
+ Stable tag: 4.8
8
License: GPLv2 or later
9
License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
25
>This plugin started as a complete retool of the "Click To Tweet" plugin by Todaymade. In addition to the user-focused changes above, the under-the-hood changes include correct character counting when dealing with non-Roman characters, translation-readiness, and use of the official shortcode API (which means security and forward-compatibility)
26
27
28
+ **Speaking of the area under the hood:** developers, please hop in and suggest improvements. You can submit pull requests at the [github repo](https://github.com/Benunc/better-click-to-tweet "plugin github repo") for this plugin.
29
30
Huge thanks to Andrew Norcross @norcross for the help with making the plugin even better as of v4.0 with enhancements to the Visual Editor's button. But you can't blame him for any of the other code!
31
32
+ Translation is now managed at [the official WordPress translation page](https://translate.wordpress.org/projects/wp-plugins/better-click-to-tweet "WordPress translation"). Thanks to the folks who helped translate in the past.
33
34
== Installation ==
35
101
102
== Changelog ==
103
104
+ = 4.8 =
105
+ * made span classes filterable, so that other developers don't hate me when they try to extend the plugin.
106
+ * I know that first point doesn't sound like much, but it's huge for developer geeks. You're just gonna have to trust me.
107
+ * removed the names of translators from the "description" since they are now being handled by official language packs, and giving credit where it is due was getting complicated.
108
+
109
= 4.7.1 =
110
* updated links throughout the back end of the plugin to send me money, for people who are into that sort of thing. Shoutout to https://givewp.com for the SWEET donation integration on my site.
111