Version Description
- Related Content
- New or modified posts are now automatically updated in your Shareaholic Related Content index within an hour!
Download this release
Release Info
Developer | shareaholic |
Plugin | WordPress Social Tools, Related Posts, Monetization – Shareaholic |
Version | 7.0.5.0 |
Comparing to | |
See all releases |
Code changes from version 7.0.4.9 to 7.0.5.0
- admin.php +1 -1
- readme.txt +13 -6
- shareaholic.php +15 -7
- utilities.php +37 -1
admin.php
CHANGED
@@ -368,4 +368,4 @@ class ShareaholicAdmin {
|
|
368 |
}
|
369 |
}
|
370 |
}
|
371 |
-
?>
|
368 |
}
|
369 |
}
|
370 |
}
|
371 |
+
?>
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: shareaholic
|
|
3 |
Tags: sexybookmarks, shareaholic, shareholic, facebook, twitter, linkedin, URL Shortener, bitly, tinyurl, Goo.gl, Google+1, Google Analytics, Google Plus, Google, Instapaper, Wish List, Digg, Gmail, Google Bookmarks, Translate, Tumblr, AIM, Yahoo Messenger, Delicious, StumbleUpon, mister wong, evernote, add this, addtoany, share this, sharethis, share and follow, share and enjoy, sharing is sexy, sharing is caring, yahoo, reddit, hackernews, tweet button, twitter button, fark, buffer, myspace, orkut, netlog, hubspot, weheartit, printfriendly, yammer, wanelo, pinterest, google translate, bookmarks, social, email button, social share, socialize, sociable, sharebar, bookmark button, share button, social bookmarking, bookmarks menu, bookmarking, share, seo, analytics, stats, sharing, facebook like, facebook recommend, WPMU, mutisite, shortcode, yaarp, yarpp, nrelate, outbrain, linkwithin, related content, related posts, related, popular posts, popular, thumbnails, recommendations
|
4 |
Requires at least: 2.7
|
5 |
Tested up to: 3.7.1
|
6 |
-
Stable tag: 7.0.
|
7 |
|
8 |
Adds an attractive social bookmarking menu and related content widget to your posts, pages, index, or any combination of the three.
|
9 |
|
@@ -148,6 +148,10 @@ Please see here: [Usage & Installation Instructions](https://shareaholic.com/too
|
|
148 |
|
149 |
== Changelog ==
|
150 |
|
|
|
|
|
|
|
|
|
151 |
= 7.0.4.9 =
|
152 |
* Bugfix: Fixed hardcoded database path; now dynamically pulled in via inbuilt WordPress function
|
153 |
* Confirmed that everything is humming along with WordPress 3.7.1!
|
@@ -968,20 +972,23 @@ Please see here: [Usage & Installation Instructions](https://shareaholic.com/too
|
|
968 |
|
969 |
== Upgrade Notice ==
|
970 |
|
|
|
|
|
|
|
971 |
= 7.0.4.9 =
|
972 |
-
|
973 |
|
974 |
= 7.0.4.8 =
|
975 |
-
|
976 |
|
977 |
= 7.0.4.7 =
|
978 |
-
|
979 |
|
980 |
= 7.0.4.6 =
|
981 |
-
|
982 |
|
983 |
= 7.0.4.5 =
|
984 |
-
|
985 |
|
986 |
= 7.0.4.3 =
|
987 |
Added support for shareaholic:keywords meta tag for better Recommendations and Related Content matches
|
3 |
Tags: sexybookmarks, shareaholic, shareholic, facebook, twitter, linkedin, URL Shortener, bitly, tinyurl, Goo.gl, Google+1, Google Analytics, Google Plus, Google, Instapaper, Wish List, Digg, Gmail, Google Bookmarks, Translate, Tumblr, AIM, Yahoo Messenger, Delicious, StumbleUpon, mister wong, evernote, add this, addtoany, share this, sharethis, share and follow, share and enjoy, sharing is sexy, sharing is caring, yahoo, reddit, hackernews, tweet button, twitter button, fark, buffer, myspace, orkut, netlog, hubspot, weheartit, printfriendly, yammer, wanelo, pinterest, google translate, bookmarks, social, email button, social share, socialize, sociable, sharebar, bookmark button, share button, social bookmarking, bookmarks menu, bookmarking, share, seo, analytics, stats, sharing, facebook like, facebook recommend, WPMU, mutisite, shortcode, yaarp, yarpp, nrelate, outbrain, linkwithin, related content, related posts, related, popular posts, popular, thumbnails, recommendations
|
4 |
Requires at least: 2.7
|
5 |
Tested up to: 3.7.1
|
6 |
+
Stable tag: 7.0.5.0
|
7 |
|
8 |
Adds an attractive social bookmarking menu and related content widget to your posts, pages, index, or any combination of the three.
|
9 |
|
148 |
|
149 |
== Changelog ==
|
150 |
|
151 |
+
= 7.0.5.0 =
|
152 |
+
* Related Content
|
153 |
+
* New or modified posts are now automatically updated in your Shareaholic Related Content index within an hour!
|
154 |
+
|
155 |
= 7.0.4.9 =
|
156 |
* Bugfix: Fixed hardcoded database path; now dynamically pulled in via inbuilt WordPress function
|
157 |
* Confirmed that everything is humming along with WordPress 3.7.1!
|
972 |
|
973 |
== Upgrade Notice ==
|
974 |
|
975 |
+
= 7.0.5.0 =
|
976 |
+
New or modified posts are now automatically updated in your Shareaholic Related Content index within an hour!
|
977 |
+
|
978 |
= 7.0.4.9 =
|
979 |
+
Bugfixes and confirmed that everything is humming along with WordPress 3.7.1!
|
980 |
|
981 |
= 7.0.4.8 =
|
982 |
+
Related Content now excludes attachments automatically. You can now also exclude *any* of your posts from Related Content via post and page metabox options.
|
983 |
|
984 |
= 7.0.4.7 =
|
985 |
+
Support for additional Shareaholic content meta tags! More improvements for Related Content.
|
986 |
|
987 |
= 7.0.4.6 =
|
988 |
+
Significant upgrade to keyword generation for Related Content. Additional fixes for those using Cloudflare.
|
989 |
|
990 |
= 7.0.4.5 =
|
991 |
+
Enforce Internet Explorer compatibility mode to latest version available; fixes a lot of general issues with Internet Explorer. Recommended update.
|
992 |
|
993 |
= 7.0.4.3 =
|
994 |
Added support for shareaholic:keywords meta tag for better Recommendations and Related Content matches
|
shareaholic.php
CHANGED
@@ -3,14 +3,14 @@
|
|
3 |
* The main file!
|
4 |
*
|
5 |
* @package shareaholic
|
6 |
-
* @version 7.0.
|
7 |
*/
|
8 |
|
9 |
/*
|
10 |
Plugin Name: Shareaholic | share buttons, analytics, related content
|
11 |
Plugin URI: https://shareaholic.com/publishers/
|
12 |
Description: Whether you want to get people sharing, grow your fans, make money, or know who's reading your content, Shareaholic will help you get it done. See <a href="admin.php?page=shareaholic-settings">configuration panel</a> for more settings.
|
13 |
-
Version: 7.0.
|
14 |
Author: Shareaholic
|
15 |
Author URI: https://shareaholic.com
|
16 |
Text Domain: shareaholic
|
@@ -53,7 +53,9 @@ require_once(SHAREAHOLIC_DIR . '/deprecation.php');
|
|
53 |
*/
|
54 |
class Shareaholic {
|
55 |
const URL = 'https://shareaholic.com';
|
56 |
-
const
|
|
|
|
|
57 |
/**
|
58 |
* Starts off as false so that ::get_instance() returns
|
59 |
* a new instance.
|
@@ -84,10 +86,16 @@ class Shareaholic {
|
|
84 |
if (!ShareaholicUtilities::has_accepted_terms_of_service()) {
|
85 |
add_action('admin_notices', array('ShareaholicAdmin', 'show_terms_of_service'));
|
86 |
}
|
87 |
-
|
88 |
-
add_action('publish_post', array('ShareaholicNotifier', 'post_notify'));
|
89 |
-
add_action('publish_page', array('ShareaholicNotifier', 'post_notify'));
|
90 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
91 |
register_activation_hook(__FILE__, array($this, 'after_activation'));
|
92 |
register_deactivation_hook( __FILE__, array($this, 'deactivate'));
|
93 |
register_uninstall_hook(__FILE__, array('Shareaholic', 'uninstall'));
|
3 |
* The main file!
|
4 |
*
|
5 |
* @package shareaholic
|
6 |
+
* @version 7.0.5.0
|
7 |
*/
|
8 |
|
9 |
/*
|
10 |
Plugin Name: Shareaholic | share buttons, analytics, related content
|
11 |
Plugin URI: https://shareaholic.com/publishers/
|
12 |
Description: Whether you want to get people sharing, grow your fans, make money, or know who's reading your content, Shareaholic will help you get it done. See <a href="admin.php?page=shareaholic-settings">configuration panel</a> for more settings.
|
13 |
+
Version: 7.0.5.0
|
14 |
Author: Shareaholic
|
15 |
Author URI: https://shareaholic.com
|
16 |
Text Domain: shareaholic
|
53 |
*/
|
54 |
class Shareaholic {
|
55 |
const URL = 'https://shareaholic.com';
|
56 |
+
const URL_CM = 'https://cm.shareaholic.com';
|
57 |
+
const VERSION = '7.0.5.0';
|
58 |
+
|
59 |
/**
|
60 |
* Starts off as false so that ::get_instance() returns
|
61 |
* a new instance.
|
86 |
if (!ShareaholicUtilities::has_accepted_terms_of_service()) {
|
87 |
add_action('admin_notices', array('ShareaholicAdmin', 'show_terms_of_service'));
|
88 |
}
|
89 |
+
|
90 |
+
// add_action('publish_post', array('ShareaholicNotifier', 'post_notify'));
|
91 |
+
// add_action('publish_page', array('ShareaholicNotifier', 'post_notify'));
|
92 |
+
|
93 |
+
// Check if at least one Related Content location is enabled, if so, notify CM when a new post is published
|
94 |
+
if (ShareaholicUtilities::should_notify_cm()) {
|
95 |
+
add_action('publish_post', array('ShareaholicUtilities', 'notify_content_manager'));
|
96 |
+
add_action('publish_page', array('ShareaholicUtilities', 'notify_content_manager'));
|
97 |
+
}
|
98 |
+
|
99 |
register_activation_hook(__FILE__, array($this, 'after_activation'));
|
100 |
register_deactivation_hook( __FILE__, array($this, 'deactivate'));
|
101 |
register_uninstall_hook(__FILE__, array('Shareaholic', 'uninstall'));
|
utilities.php
CHANGED
@@ -101,7 +101,7 @@ class ShareaholicUtilities {
|
|
101 |
public static function has_accepted_terms_of_service() {
|
102 |
return get_option('shareaholic_has_accepted_tos');
|
103 |
}
|
104 |
-
|
105 |
/**
|
106 |
* Accepts the terms of service.
|
107 |
*/
|
@@ -668,6 +668,42 @@ class ShareaholicUtilities {
|
|
668 |
}
|
669 |
}
|
670 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
671 |
/**
|
672 |
* This is a wrapper for the Event API
|
673 |
*
|
101 |
public static function has_accepted_terms_of_service() {
|
102 |
return get_option('shareaholic_has_accepted_tos');
|
103 |
}
|
104 |
+
|
105 |
/**
|
106 |
* Accepts the terms of service.
|
107 |
*/
|
668 |
}
|
669 |
}
|
670 |
|
671 |
+
/**
|
672 |
+
* Answers whether we should ping CM
|
673 |
+
*
|
674 |
+
* @return bool
|
675 |
+
*/
|
676 |
+
public static function should_notify_cm() {
|
677 |
+
$settings = ShareaholicUtilities::get_settings();
|
678 |
+
$recommendations_settings = $settings["recommendations"];
|
679 |
+
|
680 |
+
if (in_array("on", $recommendations_settings)) {
|
681 |
+
return true;
|
682 |
+
} else {
|
683 |
+
return false;
|
684 |
+
}
|
685 |
+
}
|
686 |
+
|
687 |
+
/**
|
688 |
+
* This is a wrapper for Shareaholic Content Manager API's
|
689 |
+
*
|
690 |
+
* @param string $post_id
|
691 |
+
*/
|
692 |
+
public static function notify_content_manager($post_id = NULL) {
|
693 |
+
$post_permalink = get_permalink($post_id);
|
694 |
+
|
695 |
+
if ($post_permalink != NULL) {
|
696 |
+
$cm_single_page_job_url = Shareaholic::URL_CM . '/jobs/single_page';
|
697 |
+
$payload = array (
|
698 |
+
'args' => array (
|
699 |
+
$post_permalink,
|
700 |
+
array ('force' => true)
|
701 |
+
)
|
702 |
+
);
|
703 |
+
$response = ShareaholicCurl::post($cm_single_page_job_url, $payload, 'json');
|
704 |
+
}
|
705 |
+
}
|
706 |
+
|
707 |
/**
|
708 |
* This is a wrapper for the Event API
|
709 |
*
|