Version Description
- Fixed option to display share buttons inside categories and tags
Download this release
Release Info
Developer | kasal |
Plugin | Hupso Share Buttons for Twitter, Facebook & Google+ |
Version | 2.2 |
Comparing to | |
See all releases |
Code changes from version 2.1 to 2.2
- readme.txt +4 -1
- share-buttons-hupso.php +30 -5
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: http://www.hupso.com/
|
|
4 |
Tags: twitter, facebook, google+, social, sharing, stumbleupon, addthis, sharethis, sexybookmarks, addtoany, lockerz, shareaholic
|
5 |
Requires at least: 2.8
|
6 |
Tested up to: 3.4
|
7 |
-
Stable tag: 2.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -83,6 +83,9 @@ Yes. Thay are free and will always be free. And you do not need to open any acco
|
|
83 |
|
84 |
== Changelog ==
|
85 |
|
|
|
|
|
|
|
86 |
= 2.1 =
|
87 |
* Better support for right-to-left (RTL) scripts/languages (Arabic, Persian, Urdu, Hebrew, Yiddish, Syriac, Thaana/Dhivehi, N'Ko, Chinese, Japanese)
|
88 |
|
4 |
Tags: twitter, facebook, google+, social, sharing, stumbleupon, addthis, sharethis, sexybookmarks, addtoany, lockerz, shareaholic
|
5 |
Requires at least: 2.8
|
6 |
Tested up to: 3.4
|
7 |
+
Stable tag: 2.2
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
83 |
|
84 |
== Changelog ==
|
85 |
|
86 |
+
= 2.2 =
|
87 |
+
* Fixed option to display share buttons inside categories and tags
|
88 |
+
|
89 |
= 2.1 =
|
90 |
* Better support for right-to-left (RTL) scripts/languages (Arabic, Persian, Urdu, Hebrew, Yiddish, Syriac, Thaana/Dhivehi, N'Ko, Chinese, Japanese)
|
91 |
|
share-buttons-hupso.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Hupso Share Buttons for Twitter, Facebook & Google+
|
4 |
Plugin URI: http://www.hupso.com/share
|
5 |
Description: Add simple social sharing buttons to your articles. Your visitors will be able to easily share your content on the most popular social networks: Twitter, Facebook, Google Plus, Linkedin, StumbleUpon, Digg, Reddit, Bebo and Delicous. These services are used by millions of people every day, so sharing your content there will increase traffic to your website.
|
6 |
-
Version: 2.
|
7 |
Author: kasal
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
@@ -11,10 +11,15 @@ License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
|
11 |
|
12 |
|
13 |
|
|
|
|
|
|
|
14 |
$hupso_plugin_url = plugins_url() . '/hupso-share-buttons-for-twitter-facebook-google';
|
15 |
-
add_filter( 'the_content', 'hupso_the_content',
|
16 |
-
|
|
|
17 |
|
|
|
18 |
|
19 |
if ( is_admin() ) {
|
20 |
add_filter('plugin_action_links', 'hupso_plugin_action_links', 10, 2);
|
@@ -44,6 +49,19 @@ function hupso_admin_head() {
|
|
44 |
}
|
45 |
}
|
46 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
47 |
function hupso_admin_settings_show() {
|
48 |
global $all_services, $default_services, $hupso_plugin_url;
|
49 |
|
@@ -324,7 +342,7 @@ function hupso_admin_settings_save() {
|
|
324 |
|
325 |
function hupso_the_content( $content ) {
|
326 |
|
327 |
-
global $hupso_plugin_url, $wp_version;
|
328 |
|
329 |
/* Do not show share buttons in feeds */
|
330 |
if ( is_feed() ) {
|
@@ -423,7 +441,14 @@ function hupso_the_content( $content ) {
|
|
423 |
else
|
424 |
$new_content = $code . '<br/>' . $content;
|
425 |
|
426 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
427 |
}
|
428 |
|
429 |
function hupso_settings_print_services() {
|
3 |
Plugin Name: Hupso Share Buttons for Twitter, Facebook & Google+
|
4 |
Plugin URI: http://www.hupso.com/share
|
5 |
Description: Add simple social sharing buttons to your articles. Your visitors will be able to easily share your content on the most popular social networks: Twitter, Facebook, Google Plus, Linkedin, StumbleUpon, Digg, Reddit, Bebo and Delicous. These services are used by millions of people every day, so sharing your content there will increase traffic to your website.
|
6 |
+
Version: 2.2
|
7 |
Author: kasal
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
12 |
|
13 |
|
14 |
+
$hupso_excerpt = false;
|
15 |
+
$hupso_code = '';
|
16 |
+
|
17 |
$hupso_plugin_url = plugins_url() . '/hupso-share-buttons-for-twitter-facebook-google';
|
18 |
+
add_filter( 'the_content', 'hupso_the_content', 10 );
|
19 |
+
add_filter( 'get_the_excerpt', 'hupso_get_the_excerpt', 1);
|
20 |
+
add_filter( 'the_excerpt', 'hupso_the_excerpt', 100 );
|
21 |
|
22 |
+
load_plugin_textdomain( 'share_buttons_hupso', false, dirname( __FILE__ ) . '/languages' );
|
23 |
|
24 |
if ( is_admin() ) {
|
25 |
add_filter('plugin_action_links', 'hupso_plugin_action_links', 10, 2);
|
49 |
}
|
50 |
}
|
51 |
|
52 |
+
function hupso_get_the_excerpt($param) {
|
53 |
+
global $hupso_excerpt;
|
54 |
+
$hupso_excerpt = true;
|
55 |
+
}
|
56 |
+
|
57 |
+
function hupso_the_excerpt() {
|
58 |
+
global $hupso_code;
|
59 |
+
|
60 |
+
if ( $hupso_code != '' ) {
|
61 |
+
echo $hupso_code;
|
62 |
+
}
|
63 |
+
}
|
64 |
+
|
65 |
function hupso_admin_settings_show() {
|
66 |
global $all_services, $default_services, $hupso_plugin_url;
|
67 |
|
342 |
|
343 |
function hupso_the_content( $content ) {
|
344 |
|
345 |
+
global $hupso_plugin_url, $wp_version, $hupso_excerpt, $hupso_code;
|
346 |
|
347 |
/* Do not show share buttons in feeds */
|
348 |
if ( is_feed() ) {
|
441 |
else
|
442 |
$new_content = $code . '<br/>' . $content;
|
443 |
|
444 |
+
|
445 |
+
if ( $hupso_excerpt ) {
|
446 |
+
$hupso_code = $new_content;
|
447 |
+
return $content;
|
448 |
+
}
|
449 |
+
else {
|
450 |
+
return $new_content;
|
451 |
+
}
|
452 |
}
|
453 |
|
454 |
function hupso_settings_print_services() {
|