AddToAny Share Buttons - Version 0.9.9.5.7

Version Description

Download this release

Release Info

Developer micropat
Plugin Icon 128x128 AddToAny Share Buttons
Version 0.9.9.5.7
Comparing to
See all releases

Code changes from version 0.9.9.5.6 to 0.9.9.5.7

Files changed (2) hide show
  1. README.txt +12 -4
  2. add-to-any.php +43 -28
README.txt CHANGED
@@ -3,17 +3,17 @@ Contributors: micropat
3
  Tags: sharing, share, sharethis, bookmarking, social, social bookmarking, social bookmarks, bookmark, bookmarks, save, Post, posts, page, pages, images, image, admin, statistics, stats, links, plugin, widget, e-mail, email, seo, button, delicious, google buzz, buzz, google, digg, reddit, facebook, myspace, twitter, stumbleupon, technorati, icon, icons, wpmu, addtoany, add, any
4
  Requires at least: 2.0
5
  Tested up to: 3.0
6
- Stable tag: 0.9.9.5.6
7
 
8
- Help readers share, bookmark, and email your posts & pages using any service, such as Facebook, Twitter, Google Buzz, Digg, Delicious and many more.
9
 
10
  == Description ==
11
 
12
- Help readers **share**, **save**, **bookmark**, and **email** your posts and pages using **any service**, such as Facebook, Twitter, Google Buzz, Digg, Delicious, and over 100 more social bookmarking and sharing sites. The button comes with AddToAny's customizable **Smart Menu**, which **places the services visitors use at the top of the menu**, based on each visitor's browsing and usage history.
13
 
14
  <a href="http://www.addtoany.com/" title="Sharing and bookmarking button widget" target="_blank">Share Button</a> (demo)
15
 
16
- The E-mail tab makes it easy to share via Google Mail, Yahoo! Mail, Hotmail, AOL, and any other web-based e-mailer or desktop program. The **Add to Favorites** button (or Bookmark tab) helps users bookmark using any browser (Internet Explorer, Firefox, Chrome, Safari, Opera, etc.).
17
 
18
  Individual **service icons** let you optimize your blog posts for specific social sites. Choose from over 100 individual services.
19
 
@@ -25,6 +25,8 @@ Individual **service icons** let you optimize your blog posts for specific socia
25
  * WordPress optimized, localized (English, Chinese, Spanish, Japanese, French, Portuguese, Italian, Danish, Catalan, Russian, Albanian, Romanian, Belarusian)
26
  * Many more publisher and user features!
27
 
 
 
28
  <a href="http://www.addtoany.com/share_save" title="Share" target="_blank">Share this plugin</a>
29
 
30
  See also:
@@ -169,6 +171,12 @@ This is done to overcome browser limitations that prevent the drop-down menu fro
169
 
170
  == Changelog ==
171
 
 
 
 
 
 
 
172
  = .9.9.5.6 =
173
  * Fix PHP warnings when there are no arguments from functions ADDTOANY_SHARE_SAVE_BUTTON or ADDTOANY_SHARE_SAVE_ICONS
174
  * Italian translation update (by <a href="http://gidibao.net/">Gianni</a>)
3
  Tags: sharing, share, sharethis, bookmarking, social, social bookmarking, social bookmarks, bookmark, bookmarks, save, Post, posts, page, pages, images, image, admin, statistics, stats, links, plugin, widget, e-mail, email, seo, button, delicious, google buzz, buzz, google, digg, reddit, facebook, myspace, twitter, stumbleupon, technorati, icon, icons, wpmu, addtoany, add, any
4
  Requires at least: 2.0
5
  Tested up to: 3.0
6
+ Stable tag: 0.9.9.5.7
7
 
8
+ Help people share, bookmark, and email your posts & pages using any service, such as Facebook, Twitter, Google Buzz, Digg and many more.
9
 
10
  == Description ==
11
 
12
+ The most complete plugin to help people **share**, **bookmark**, and **email** your posts and pages using **any service**, such as Facebook, Twitter, Google Buzz, Digg, Delicious, and well over 100 more social bookmarking and sharing sites. The button comes with AddToAny's customizable **Smart Menu**, which **places the services visitors use at the top of the menu**, based on each visitor's browsing and usage history.
13
 
14
  <a href="http://www.addtoany.com/" title="Sharing and bookmarking button widget" target="_blank">Share Button</a> (demo)
15
 
16
+ The E-mail tab makes it easy to share via Google Gmail, Yahoo! Mail, Hotmail, AOL, and any other web-based e-mailer or desktop program. The **Add to Favorites** button (or Bookmark tab) helps users bookmark using any browser (Internet Explorer, Firefox, Chrome, Safari, Opera, etc.).
17
 
18
  Individual **service icons** let you optimize your blog posts for specific social sites. Choose from over 100 individual services.
19
 
25
  * WordPress optimized, localized (English, Chinese, Spanish, Japanese, French, Portuguese, Italian, Danish, Catalan, Russian, Albanian, Romanian, Belarusian)
26
  * Many more publisher and user features!
27
 
28
+ After **years of ongoing development**, close to **1 million downloads**, and **ongoing support** from the community, AddToAny still strives to be the best WordPress plugin for sharing. We hope it's perfect for everyone by version 1.0.
29
+
30
  <a href="http://www.addtoany.com/share_save" title="Share" target="_blank">Share this plugin</a>
31
 
32
  See also:
171
 
172
  == Changelog ==
173
 
174
+ = .9.9.5.7 =
175
+ * Work around "Featured Posts" excerpt scenarios that would stop button auto-placement below post content
176
+ * Work around WP core issue to use HTTPS/SSL for static content files, like standalone icons and files in admin
177
+ * http://core.trac.wordpress.org/ticket/13941
178
+ * Admin style consistency
179
+
180
  = .9.9.5.6 =
181
  * Fix PHP warnings when there are no arguments from functions ADDTOANY_SHARE_SAVE_BUTTON or ADDTOANY_SHARE_SAVE_ICONS
182
  * Italian translation update (by <a href="http://gidibao.net/">Gianni</a>)
add-to-any.php CHANGED
@@ -2,8 +2,8 @@
2
  /*
3
  Plugin Name: AddToAny: Share/Bookmark/Email Button
4
  Plugin URI: http://www.addtoany.com/
5
- Description: Help readers share, bookmark, and email your posts and pages using any service. [<a href="options-general.php?page=add-to-any.php">Settings</a>]
6
- Version: .9.9.5.6
7
  Author: AddToAny
8
  Author URI: http://www.addtoany.com/
9
  */
@@ -13,13 +13,17 @@ if( !isset($A2A_locale) )
13
 
14
  // Pre-2.6 compatibility
15
  if ( !defined('WP_CONTENT_URL') )
16
- define( 'WP_CONTENT_URL', get_option('siteurl') . '/wp-content');
17
  if ( ! defined( 'WP_PLUGIN_URL' ) )
18
- define( 'WP_PLUGIN_URL', WP_CONTENT_URL. '/plugins' );
19
-
20
  $A2A_SHARE_SAVE_plugin_basename = plugin_basename(dirname(__FILE__));
21
  $A2A_SHARE_SAVE_plugin_url_path = WP_PLUGIN_URL.'/'.$A2A_SHARE_SAVE_plugin_basename; // /wp-content/plugins/add-to-any
22
 
 
 
 
 
23
  function A2A_SHARE_SAVE_textdomain() {
24
  global $A2A_SHARE_SAVE_plugin_url_path, $A2A_SHARE_SAVE_plugin_basename;
25
 
@@ -299,8 +303,22 @@ function A2A_SHARE_SAVE_auto_placement($title) {
299
  }
300
 
301
 
 
 
 
302
  function A2A_SHARE_SAVE_remove_from_content($content) {
303
  remove_filter('the_content', 'A2A_SHARE_SAVE_to_bottom_of_content', 98);
 
 
 
 
 
 
 
 
 
 
 
304
  return $content;
305
  }
306
 
@@ -369,7 +387,7 @@ function A2A_SHARE_SAVE_to_bottom_of_content($content) {
369
  return $content;
370
  }
371
 
372
- // Only automatically output button code after the_title has been called - to avoid premature calling from misc. the_content filters
373
  add_filter('the_title', 'A2A_SHARE_SAVE_auto_placement', 9);
374
  add_filter('the_content', 'A2A_SHARE_SAVE_to_bottom_of_content', 98);
375
 
@@ -760,28 +778,25 @@ function A2A_SHARE_SAVE_options_page() {
760
  <tr valign="top">
761
  <th scope="row"><?php _e('Advanced Options', 'add-to-any'); ?></th>
762
  <td><fieldset>
763
- <p>
764
- <label for="A2A_SHARE_SAVE_inline_css">
765
- <input name="A2A_SHARE_SAVE_inline_css" id="A2A_SHARE_SAVE_inline_css"
766
- type="checkbox"<?php if(get_option('A2A_SHARE_SAVE_inline_css')!='-1') echo ' checked="checked"'; ?> value="1"/>
767
- <?php _e('Use CSS stylesheet', 'add-to-any'); ?> <strong>**</strong>
768
- </label>
769
- </p>
770
- <p>
771
- <label for="A2A_SHARE_SAVE_cache">
772
- <input name="A2A_SHARE_SAVE_cache" id="A2A_SHARE_SAVE_cache"
773
- type="checkbox"<?php if(get_option('A2A_SHARE_SAVE_cache')=='1') echo ' checked="checked"'; ?> value="1"/>
774
- <?php _e('Cache AddToAny locally with daily cache updates', 'add-to-any'); ?> <strong>***</strong>
775
- </label>
776
- </p>
777
- <div class="setting-description">
778
- <strong>**</strong> <?php _e("If unchecked, be sure to place the CSS in your theme's stylesheet:", "add-to-any"); ?> <span id="addtoany_show_css_code" class="button-secondary">&#187;</span>
779
- <p id="addtoany_css_code">
780
- <textarea class="code" style="width:98%;font-size:12px" rows="12" cols="50"><?php A2A_SHARE_SAVE_button_css(TRUE) ?></textarea>
781
- </p>
782
- <br/>
783
- <strong>***</strong> <?php _e("Only consider for high-traffic sites. Be sure to set far future cache/expires headers for image files in your <code>uploads/addtoany</code> directory.", "add-to-any"); ?>
784
- </div>
785
  </fieldset></td>
786
  </tr>
787
  </table>
2
  /*
3
  Plugin Name: AddToAny: Share/Bookmark/Email Button
4
  Plugin URI: http://www.addtoany.com/
5
+ Description: Help people share, bookmark, and email your posts & pages using any service, such as Facebook, Twitter, Google Buzz, Digg and many more. [<a href="options-general.php?page=add-to-any.php">Settings</a>]
6
+ Version: .9.9.5.7
7
  Author: AddToAny
8
  Author URI: http://www.addtoany.com/
9
  */
13
 
14
  // Pre-2.6 compatibility
15
  if ( !defined('WP_CONTENT_URL') )
16
+ define( 'WP_CONTENT_URL', get_option('siteurl') . '/wp-content');
17
  if ( ! defined( 'WP_PLUGIN_URL' ) )
18
+ define( 'WP_PLUGIN_URL', WP_CONTENT_URL . '/plugins' );
19
+
20
  $A2A_SHARE_SAVE_plugin_basename = plugin_basename(dirname(__FILE__));
21
  $A2A_SHARE_SAVE_plugin_url_path = WP_PLUGIN_URL.'/'.$A2A_SHARE_SAVE_plugin_basename; // /wp-content/plugins/add-to-any
22
 
23
+ // Fix SSL
24
+ if (function_exists('is_ssl') && is_ssl()) // @since 2.6.0
25
+ $A2A_SHARE_SAVE_plugin_url_path = str_replace('http:', 'https:', $A2A_SHARE_SAVE_plugin_url_path);
26
+
27
  function A2A_SHARE_SAVE_textdomain() {
28
  global $A2A_SHARE_SAVE_plugin_url_path, $A2A_SHARE_SAVE_plugin_basename;
29
 
303
  }
304
 
305
 
306
+ /**
307
+ * Remove the_content filter and add it for next time
308
+ */
309
  function A2A_SHARE_SAVE_remove_from_content($content) {
310
  remove_filter('the_content', 'A2A_SHARE_SAVE_to_bottom_of_content', 98);
311
+ add_filter('the_content', 'A2A_SHARE_SAVE_to_bottom_of_content_next_time', 98);
312
+
313
+ return $content;
314
+ }
315
+
316
+ /**
317
+ * Apply the_content filter "next time"
318
+ */
319
+ function A2A_SHARE_SAVE_to_bottom_of_content_next_time($content) {
320
+ add_filter('the_content', 'A2A_SHARE_SAVE_to_bottom_of_content', 98);
321
+
322
  return $content;
323
  }
324
 
387
  return $content;
388
  }
389
 
390
+ // Only automatically output button code after the_title has been called - to avoid premature calling from misc. the_content filters (especially meta description)
391
  add_filter('the_title', 'A2A_SHARE_SAVE_auto_placement', 9);
392
  add_filter('the_content', 'A2A_SHARE_SAVE_to_bottom_of_content', 98);
393
 
778
  <tr valign="top">
779
  <th scope="row"><?php _e('Advanced Options', 'add-to-any'); ?></th>
780
  <td><fieldset>
781
+ <label for="A2A_SHARE_SAVE_inline_css">
782
+ <input name="A2A_SHARE_SAVE_inline_css" id="A2A_SHARE_SAVE_inline_css"
783
+ type="checkbox"<?php if(get_option('A2A_SHARE_SAVE_inline_css')!='-1') echo ' checked="checked"'; ?> value="1"/>
784
+ <?php _e('Use CSS stylesheet', 'add-to-any'); ?> <strong>**</strong>
785
+ </label><br/>
786
+ <label for="A2A_SHARE_SAVE_cache">
787
+ <input name="A2A_SHARE_SAVE_cache" id="A2A_SHARE_SAVE_cache"
788
+ type="checkbox"<?php if(get_option('A2A_SHARE_SAVE_cache')=='1') echo ' checked="checked"'; ?> value="1"/>
789
+ <?php _e('Cache AddToAny locally with daily cache updates', 'add-to-any'); ?> <strong>***</strong>
790
+ </label>
791
+ <br/><br/>
792
+ <div class="setting-description">
793
+ <strong>**</strong> <?php _e("If unchecked, be sure to place the CSS in your theme's stylesheet:", "add-to-any"); ?> <span id="addtoany_show_css_code" class="button-secondary">&#187;</span>
794
+ <p id="addtoany_css_code">
795
+ <textarea class="code" style="width:98%;font-size:12px" rows="12" cols="50"><?php A2A_SHARE_SAVE_button_css(TRUE) ?></textarea>
796
+ </p>
797
+ <br/>
798
+ <strong>***</strong> <?php _e("Only consider for sites with frequently returning visitors. Since many visitors will have AddToAny cached in their browser already, serving AddToAny locally from your site will be slower for those visitors. Be sure to set far future cache/expires headers for image files in your <code>uploads/addtoany</code> directory.", "add-to-any"); ?>
799
+ </div>
 
 
 
800
  </fieldset></td>
801
  </tr>
802
  </table>