WordPress Social Tools, Related Posts, Monetization – Shareaholic - Version 7.0.0.4

Version Description

  • Several bug fixes, in addition to -
  • Huge update! The plugin has been completely re-written from the ground up to be faster, simpler to use
  • Choose from snazzy new Related Post themes
  • Related Posts now come mobile optimized and responsive out of the box - Shareaholic automagically determines how many Related Posts to show given how much screen width it is given
  • Customize your "You may also like" Related Posts text
  • Option to exclude any URL from Related Posts
  • Choose from new Share button themes! (including vertical share buttons!)
  • Additional URL shortener options
Download this release

Release Info

Developer shareaholic
Plugin Icon 128x128 WordPress Social Tools, Related Posts, Monetization – Shareaholic
Version 7.0.0.4
Comparing to
See all releases

Code changes from version 7.0.0.3 to 7.0.0.4

Files changed (5) hide show
  1. curl.php +13 -3
  2. languages/shareaholic.pot +171 -0
  3. readme.txt +23 -5
  4. shareaholic.php +2 -2
  5. utilities.php +2 -2
curl.php CHANGED
@@ -21,7 +21,7 @@ class ShareaholicCurl {
21
  * @return array the returned data json decoded
22
  */
23
  public static function post($url, $data = array(), $data_type = '') {
24
- return self::send_request($url, $data, $data_type, 'POST');
25
  }
26
 
27
  /**
@@ -34,7 +34,18 @@ class ShareaholicCurl {
34
  * @return array the returned data json decoded
35
  */
36
  public static function get($url, $data = array(), $data_type = '') {
37
- return self::send_request($url, $data, $data_type, 'GET');
 
 
 
 
 
 
 
 
 
 
 
38
  }
39
 
40
  /**
@@ -49,7 +60,6 @@ class ShareaholicCurl {
49
  * @return array the returned data json decoded
50
  */
51
  private static function send_request($url, $data, $data_type, $method) {
52
- ShareaholicUtilities::log($data);
53
  $curl = curl_init();
54
  curl_setopt_array($curl, array(
55
  CURLOPT_URL => $url,
21
  * @return array the returned data json decoded
22
  */
23
  public static function post($url, $data = array(), $data_type = '') {
24
+ return self::send_request_with_wp($url, $data, $data_type, 'POST');
25
  }
26
 
27
  /**
34
  * @return array the returned data json decoded
35
  */
36
  public static function get($url, $data = array(), $data_type = '') {
37
+ return self::send_request_with_wp($url, $data, $data_type, 'GET');
38
+ }
39
+
40
+ private static function send_request_with_wp($url, $data, $data_type, $method) {
41
+ if ($method == 'GET') {
42
+ $response = wp_remote_get($url, array('body' => $data));
43
+ } elseif ($method == 'POST') {
44
+ $response = wp_remote_post($url, array('body' => $data));
45
+ }
46
+ $result = $response['body'];
47
+ return ShareaholicUtilities::object_to_array(json_decode($result)) ?
48
+ ShareaholicUtilities::object_to_array(json_decode($result)) : $result;
49
  }
50
 
51
  /**
60
  * @return array the returned data json decoded
61
  */
62
  private static function send_request($url, $data, $data_type, $method) {
 
63
  $curl = curl_init();
64
  curl_setopt_array($curl, array(
65
  CURLOPT_URL => $url,
languages/shareaholic.pot ADDED
@@ -0,0 +1,171 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2013 Shareaholic | share buttons, analytics, related content
2
+ # This file is distributed under the same license as the Shareaholic | share buttons, analytics, related content package.
3
+ msgid ""
4
+ msgstr ""
5
+ "Project-Id-Version: Shareaholic | share buttons, analytics, related content "
6
+ "7.0.0.3\n"
7
+ "Report-Msgid-Bugs-To: http://wordpress.org/tag/shareaholic\n"
8
+ "POT-Creation-Date: 2013-07-01 21:13:09+00:00\n"
9
+ "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
+ "Content-Transfer-Encoding: 8bit\n"
12
+ "PO-Revision-Date: 2013-MO-DA HO:MI+ZONE\n"
13
+ "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14
+ "Language-Team: LANGUAGE <LL@li.org>\n"
15
+
16
+ #: templates/advanced_settings.php:3
17
+ msgid "Shareaholic: Advanced Settings"
18
+ msgstr ""
19
+
20
+ #: templates/advanced_settings.php:5
21
+ msgid ""
22
+ "You rarely need to edit these settings. We recommend keeping with the "
23
+ "default. "
24
+ msgstr ""
25
+
26
+ #: templates/advanced_settings.php:15
27
+ msgid "Disable Analytics"
28
+ msgstr ""
29
+
30
+ #: templates/advanced_settings.php:15 templates/advanced_settings.php:21
31
+ msgid "(not recommended)"
32
+ msgstr ""
33
+
34
+ #: templates/advanced_settings.php:21
35
+ msgid "Do not automatically include <code>Open Graph</code> tags"
36
+ msgstr ""
37
+
38
+ #: templates/advanced_settings.php:29 templates/settings.php:71
39
+ msgid "Save Changes"
40
+ msgstr ""
41
+
42
+ #: templates/deprecation_warnings.php:6
43
+ msgid ""
44
+ "is being deprecated. Please update the code found in the following files:"
45
+ msgstr ""
46
+
47
+ #: templates/failed_to_create_api_key.php:6
48
+ #: templates/terms_of_service_notice.php:6
49
+ msgid ""
50
+ "Action required: You've installed Shareaholic for WordPress. We're ready "
51
+ "when you are. %sGet started now &raquo;%s"
52
+ msgstr ""
53
+
54
+ #: templates/failed_to_create_api_key_modal.php:2
55
+ msgid "Setup Shareaholic"
56
+ msgstr ""
57
+
58
+ #: templates/failed_to_create_api_key_modal.php:7
59
+ msgid ""
60
+ "It appears that we are having some trouble setting up Shareaholic for "
61
+ "WordPress right now. This is usually temporary. Please revisit this section "
62
+ "after a few minutes or click \"retry\" now."
63
+ msgstr ""
64
+
65
+ #: templates/failed_to_create_api_key_modal.php:12
66
+ msgid "Retry"
67
+ msgstr ""
68
+
69
+ #: templates/failed_to_create_api_key_modal.php:14
70
+ msgid "or, try again later"
71
+ msgstr ""
72
+
73
+ #: templates/footer.php:8
74
+ msgid ""
75
+ "If you like our work, show some love and %sgive us a good rating%s. Thanks "
76
+ "for using Shareaholic, made with much love in Boston, Massachusetts."
77
+ msgstr ""
78
+
79
+ #: templates/meta_boxes.php:6
80
+ msgid "Hide Share Buttons"
81
+ msgstr ""
82
+
83
+ #: templates/meta_boxes.php:15
84
+ msgid "Do not include Open Graph tags"
85
+ msgstr ""
86
+
87
+ #: templates/meta_boxes.php:24
88
+ msgid "Hide Related Content"
89
+ msgstr ""
90
+
91
+ #: templates/settings.php:3
92
+ msgid "Shareaholic: Available Apps"
93
+ msgstr ""
94
+
95
+ #: templates/settings.php:19
96
+ msgid "Share Buttons"
97
+ msgstr ""
98
+
99
+ #: templates/settings.php:46
100
+ msgid "Related Content / Recommendations"
101
+ msgstr ""
102
+
103
+ #: templates/terms_of_service_modal.php:2
104
+ msgid "Thanks for Installing"
105
+ msgstr ""
106
+
107
+ #: templates/terms_of_service_modal.php:4
108
+ msgid ""
109
+ "%sShareaholic%s gives you the essential tools you need to become a "
110
+ "successful publisher."
111
+ msgstr ""
112
+
113
+ #: templates/terms_of_service_modal.php:8
114
+ msgid ""
115
+ "%sShare buttons%s let your readers post your content to their favorite "
116
+ "networks."
117
+ msgstr ""
118
+
119
+ #: templates/terms_of_service_modal.php:12
120
+ msgid ""
121
+ "%sRelated content%s keeps people on your site and turns visitors into "
122
+ "readers."
123
+ msgstr ""
124
+
125
+ #: templates/terms_of_service_modal.php:16
126
+ msgid ""
127
+ "%sAnalytics%s gives you the insight to create tailored content and grow your "
128
+ "site."
129
+ msgstr ""
130
+
131
+ #: templates/terms_of_service_modal.php:20
132
+ msgid "Get Started"
133
+ msgstr ""
134
+
135
+ #: templates/terms_of_service_modal.php:21
136
+ msgid ""
137
+ "By clicking \"Get Started\" you agree to Shareholic's %sTerms of Service%s "
138
+ "and %sPrivacy Policy%s."
139
+ msgstr ""
140
+
141
+ #: templates/why_to_sign_up.php:102
142
+ msgid "Edit General Website Settings"
143
+ msgstr ""
144
+
145
+ #: utilities.php:76
146
+ msgid "Settings"
147
+ msgstr ""
148
+
149
+ #. Plugin Name of the plugin/theme
150
+ msgid "Shareaholic | share buttons, analytics, related content"
151
+ msgstr ""
152
+
153
+ #. Plugin URI of the plugin/theme
154
+ msgid "https://shareaholic.com/publishers/"
155
+ msgstr ""
156
+
157
+ #. Description of the plugin/theme
158
+ msgid ""
159
+ "Whether you want to get people sharing, grow your fans, make money, or know "
160
+ "who's reading your content, Shareaholic will help you get it done. See <a "
161
+ "href=\"admin.php?page=shareaholic-settings\">configuration panel</a> for "
162
+ "more settings."
163
+ msgstr ""
164
+
165
+ #. Author of the plugin/theme
166
+ msgid "Shareaholic"
167
+ msgstr ""
168
+
169
+ #. Author URI of the plugin/theme
170
+ msgid "https://shareaholic.com"
171
+ msgstr ""
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, 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.5.2
6
- Stable tag: 6.1.3.8
7
 
8
  Adds an attractive social bookmarking menu and related content widget to your posts, pages, index, or any combination of the three.
9
 
@@ -92,19 +92,36 @@ Listed here are credits and special thanks to some of you who have helped us out
92
 
93
  == Installation ==
94
 
 
 
95
  1. Upload the extracted archive to `wp-content/plugins/`
96
  2. Activate the plugin through the 'Plugins' menu
97
  3. Open the plugin settings page Settings -> Shareaholic
98
  4. Adjust settings to your liking
99
- 4. Enjoy!
 
 
 
 
 
 
 
 
 
 
100
 
101
  = Shareaholic Shortcode Support / Manual Usage =
102
 
103
- You can insert Share Buttons, Related Content, etc manually wherever you're like. Simply place the following Shortcode into your themewhere you want the corresponding app to appear:
104
 
105
  `[shareaholic app="share_buttons" id="<insert shareaholic app ID here>"]`
106
  `[shareaholic app="recommendations" id="<insert shareaholic app ID here>"]`
107
 
 
 
 
 
 
108
  Grab the corresponding App ID from your Shareaholic Dashboard for the App you want to manually insert into your theme. Shareaholic Shortcode's are full featured and support all available configuration options available. Enjoy!
109
 
110
  Old legacy methods (no longer supported as of version 7.0.0.0):
@@ -124,7 +141,8 @@ Please see here: [Usage & Installation Instructions](https://shareaholic.com/too
124
 
125
  == Changelog ==
126
 
127
- = 7.0.0.3 =
 
128
  * Huge update! The plugin has been completely re-written from the ground up to be faster, simpler to use
129
  * Choose from snazzy new Related Post themes
130
  * Related Posts now come mobile optimized and responsive out of the box - Shareaholic automagically determines how many Related Posts to show given how much screen width it is given
@@ -852,7 +870,7 @@ Please see here: [Usage & Installation Instructions](https://shareaholic.com/too
852
 
853
  == Upgrade Notice ==
854
 
855
- = 7.0.0.3 =
856
  * Huge update! Completely re-written from the ground up to be faster and with a new simple interface! Includes brand new Share button themes (including vertical share buttons!) and Related posts themes. Related Posts now come mobile optimized and responsive out of the box - Shareaholic automagically determines how many Related Posts to show given how much screen width it is given. You can now even customize your "You may also like" text and exclude URLs.
857
 
858
  = 6.1.3.5 =
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, 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.5.2
6
+ Stable tag: 7.0.0.4
7
 
8
  Adds an attractive social bookmarking menu and related content widget to your posts, pages, index, or any combination of the three.
9
 
92
 
93
  == Installation ==
94
 
95
+ *Via Upload:*
96
+
97
  1. Upload the extracted archive to `wp-content/plugins/`
98
  2. Activate the plugin through the 'Plugins' menu
99
  3. Open the plugin settings page Settings -> Shareaholic
100
  4. Adjust settings to your liking
101
+ 5. If you use a caching plugin please clear the cache
102
+ 6. Enjoy!
103
+
104
+ *Via Admin:*
105
+
106
+ 1. Go to Plugins -> Add New
107
+ 2. Search for `Shareaholic`
108
+ 3. Install the plugin called `Shareaholic` and activate it
109
+ 4. Adjust settings to your liking
110
+ 5. If you use a caching plugin please clear the cache
111
+ 6. Enjoy!
112
 
113
  = Shareaholic Shortcode Support / Manual Usage =
114
 
115
+ You can place Share Buttons, Related Content and any other Shareaholic app manually wherever you're like. Simply insert the following Shortcode where you want the corresponding app to appear:
116
 
117
  `[shareaholic app="share_buttons" id="<insert shareaholic app ID here>"]`
118
  `[shareaholic app="recommendations" id="<insert shareaholic app ID here>"]`
119
 
120
+ In your PHP / theme template code, you would add:
121
+
122
+ `<?php echo do_shortcode ('[shareaholic app="share_buttons" id="<insert shareaholic app ID here>"]'); ?>`
123
+ `<?php echo do_shortcode ('[shareaholic app="recommendations" id="<insert shareaholic app ID here>"]'); ?>`
124
+
125
  Grab the corresponding App ID from your Shareaholic Dashboard for the App you want to manually insert into your theme. Shareaholic Shortcode's are full featured and support all available configuration options available. Enjoy!
126
 
127
  Old legacy methods (no longer supported as of version 7.0.0.0):
141
 
142
  == Changelog ==
143
 
144
+ = 7.0.0.4 =
145
+ * Several bug fixes, in addition to -
146
  * Huge update! The plugin has been completely re-written from the ground up to be faster, simpler to use
147
  * Choose from snazzy new Related Post themes
148
  * Related Posts now come mobile optimized and responsive out of the box - Shareaholic automagically determines how many Related Posts to show given how much screen width it is given
870
 
871
  == Upgrade Notice ==
872
 
873
+ = 7.0.0.4 =
874
  * Huge update! Completely re-written from the ground up to be faster and with a new simple interface! Includes brand new Share button themes (including vertical share buttons!) and Related posts themes. Related Posts now come mobile optimized and responsive out of the box - Shareaholic automagically determines how many Related Posts to show given how much screen width it is given. You can now even customize your "You may also like" text and exclude URLs.
875
 
876
  = 6.1.3.5 =
shareaholic.php CHANGED
@@ -8,7 +8,7 @@
8
  Plugin Name: Shareaholic | share buttons, analytics, related content
9
  Plugin URI: https://shareaholic.com/publishers/
10
  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.
11
- Version: 7.0.0.3
12
  Author: Shareaholic
13
  Author URI: https://shareaholic.com
14
  Credits & Thanks: https://shareaholic.com/tools/wordpress/credits
@@ -39,7 +39,7 @@ require_once(SHAREAHOLIC_DIR . '/deprecation.php');
39
  */
40
  class Shareaholic {
41
  const URL = 'https://shareaholic.com';
42
- const VERSION = '7.0.0.3';
43
  private static $instance = false;
44
 
45
  /**
8
  Plugin Name: Shareaholic | share buttons, analytics, related content
9
  Plugin URI: https://shareaholic.com/publishers/
10
  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.
11
+ Version: 7.0.0.4
12
  Author: Shareaholic
13
  Author URI: https://shareaholic.com
14
  Credits & Thanks: https://shareaholic.com/tools/wordpress/credits
39
  */
40
  class Shareaholic {
41
  const URL = 'https://shareaholic.com';
42
+ const VERSION = '7.0.0.4';
43
  private static $instance = false;
44
 
45
  /**
utilities.php CHANGED
@@ -380,7 +380,7 @@ class ShareaholicUtilities {
380
  public static function get_or_create_api_key() {
381
  $settings = self::get_settings();
382
  if (isset($settings['api_key']) && !empty($settings['api_key'])) {
383
- return;
384
  }
385
  delete_option('shareaholic_settings');
386
 
@@ -523,7 +523,7 @@ class ShareaholicUtilities {
523
 
524
  // var_dump($event_params);
525
 
526
- // $result = ShareaholicCurl::post($event_api_url, $event_params);
527
  // $result = wp_remote_post($event_api_url, array('body' => $event_params) );
528
  }
529
 
380
  public static function get_or_create_api_key() {
381
  $settings = self::get_settings();
382
  if (isset($settings['api_key']) && !empty($settings['api_key'])) {
383
+ return $settings['api_key'];
384
  }
385
  delete_option('shareaholic_settings');
386
 
523
 
524
  // var_dump($event_params);
525
 
526
+ $result = ShareaholicCurl::post($event_api_url, $event_params);
527
  // $result = wp_remote_post($event_api_url, array('body' => $event_params) );
528
  }
529