AddToAny Share Buttons - Version 1.2.8.2

Version Description

  • Add pointer to settings in admin
Download this release

Release Info

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

Code changes from version 1.2.8.0 to 1.2.8.2

README.txt CHANGED
@@ -1,9 +1,9 @@
1
  === Share Buttons by AddToAny ===
2
  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, sidebar, widget, email, e-mail, seo, button, delicious, google, tumblr, linkedin, digg, reddit, facebook, facebook like, like, myspace, twitter, tweet, +1, plus 1, google plus, google plus one, plus one, pinterest, pin, pin it, pinit, messenger, stumbleupon, technorati, lockerz, addthis, sociable, sharedaddy, shareaholic, icon, icons, vector, SVG, wpmu, Add to Any, AddToAny
4
  Requires at least: 2.8
5
  Tested up to: 3.8
6
- Stable tag: 1.2.8.0
7
 
8
  Share buttons for WordPress including AddToAny's universal sharing button, Facebook, Twitter, Google+, Pinterest, StumbleUpon and many more.
9
 
@@ -238,6 +238,14 @@ Upload the plugin directory (including all files and directories within) to the
238
 
239
  == Changelog ==
240
 
 
 
 
 
 
 
 
 
241
  = 1.2.8.0 =
242
  * Update Customize documentation links
243
 
1
  === Share Buttons by AddToAny ===
2
  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, shortcode, sidebar, widget, email, e-mail, seo, button, delicious, google, tumblr, linkedin, digg, reddit, facebook, facebook like, like, twitter, tweet, +1, plus 1, google plus, google plus one, plus one, pinterest, pin, pin it, pinit, buffer, stumbleupon, technorati, lockerz, addthis, sociable, sharedaddy, shareaholic, icon, icons, vector, SVG, wpmu, Add to Any, AddToAny
4
  Requires at least: 2.8
5
  Tested up to: 3.8
6
+ Stable tag: 1.2.8.2
7
 
8
  Share buttons for WordPress including AddToAny's universal sharing button, Facebook, Twitter, Google+, Pinterest, StumbleUpon and many more.
9
 
238
 
239
  == Changelog ==
240
 
241
+ = 1.2.8.2 =
242
+ * Add pointer to settings in admin
243
+
244
+ = 1.2.8.1 =
245
+ * Remove Favoriten
246
+ * Remove Grono
247
+ * Remove Hyves
248
+
249
  = 1.2.8.0 =
250
  * Update Customize documentation links
251
 
add-to-any.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Share Buttons by AddToAny
4
  Plugin URI: http://www.addtoany.com/
5
  Description: Share buttons for your pages including AddToAny's universal sharing button, Facebook, Twitter, Google+, Pinterest, StumbleUpon and many more. [<a href="options-general.php?page=add-to-any.php">Settings</a>]
6
- Version: 1.2.8.0
7
  Author: micropat
8
  Author URI: http://www.addtoany.com/
9
  */
@@ -756,9 +756,9 @@ add_action('wp_print_styles', 'A2A_SHARE_SAVE_stylesheet');
756
 
757
 
758
 
759
- /*****************************
760
- CACHE ADDTOANY
761
- ******************************/
762
 
763
  function A2A_SHARE_SAVE_refresh_cache() {
764
  $contents = wp_remote_fopen("http://www.addtoany.com/ext/updater/files_list/");
@@ -799,9 +799,9 @@ function A2A_SHARE_SAVE_unschedule_cache() {
799
 
800
 
801
 
802
- /*****************************
803
- OPTIONS
804
- ******************************/
805
 
806
  if ( is_admin() ) {
807
  include_once( $A2A_SHARE_SAVE_plugin_dir . '/addtoany.admin.php' );
3
  Plugin Name: Share Buttons by AddToAny
4
  Plugin URI: http://www.addtoany.com/
5
  Description: Share buttons for your pages including AddToAny's universal sharing button, Facebook, Twitter, Google+, Pinterest, StumbleUpon and many more. [<a href="options-general.php?page=add-to-any.php">Settings</a>]
6
+ Version: 1.2.8.2
7
  Author: micropat
8
  Author URI: http://www.addtoany.com/
9
  */
756
 
757
 
758
 
759
+ /**
760
+ * Cache AddToAny
761
+ */
762
 
763
  function A2A_SHARE_SAVE_refresh_cache() {
764
  $contents = wp_remote_fopen("http://www.addtoany.com/ext/updater/files_list/");
799
 
800
 
801
 
802
+ /**
803
+ * Admin Options
804
+ */
805
 
806
  if ( is_admin() ) {
807
  include_once( $A2A_SHARE_SAVE_plugin_dir . '/addtoany.admin.php' );
addtoany.admin.php CHANGED
@@ -1,6 +1,8 @@
1
  <?php
2
 
3
- // Post Options
 
 
4
  function A2A_SHARE_SAVE_add_meta_box() {
5
  // get_post_types() only included in WP 2.9/3.0
6
  $post_types = ( function_exists( 'get_post_types' ) ) ? get_post_types( array( 'public' => true ) ) : array( 'post', 'page' ) ;
@@ -52,7 +54,9 @@ function A2A_SHARE_SAVE_meta_box_save( $post_id ) {
52
  add_action( 'admin_init', 'A2A_SHARE_SAVE_add_meta_box' );
53
  add_action( 'save_post', 'A2A_SHARE_SAVE_meta_box_save' );
54
 
55
-
 
 
56
  function A2A_SHARE_SAVE_migrate_options() {
57
 
58
  $options = array(
@@ -103,6 +107,72 @@ function A2A_SHARE_SAVE_migrate_options() {
103
 
104
  }
105
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
106
  function A2A_SHARE_SAVE_options_page() {
107
 
108
  global $A2A_SHARE_SAVE_plugin_url_path,
1
  <?php
2
 
3
+ /**
4
+ * Post options
5
+ */
6
  function A2A_SHARE_SAVE_add_meta_box() {
7
  // get_post_types() only included in WP 2.9/3.0
8
  $post_types = ( function_exists( 'get_post_types' ) ) ? get_post_types( array( 'public' => true ) ) : array( 'post', 'page' ) ;
54
  add_action( 'admin_init', 'A2A_SHARE_SAVE_add_meta_box' );
55
  add_action( 'save_post', 'A2A_SHARE_SAVE_meta_box_save' );
56
 
57
+ /**
58
+ * Migrate old AddToAny options
59
+ */
60
  function A2A_SHARE_SAVE_migrate_options() {
61
 
62
  $options = array(
107
 
108
  }
109
 
110
+ /**
111
+ * Adds a WordPress pointer to Settings menu, so user knows where to configure AddToAny
112
+ */
113
+ function A2A_SHARE_SAVE_enqueue_pointer_script_style( $hook_suffix ) {
114
+
115
+ // Requires WP 3.3
116
+ if ( get_bloginfo( 'version' ) < '3.3' ) {
117
+ return;
118
+ }
119
+
120
+ // Assume pointer shouldn't be shown
121
+ $enqueue_pointer_script_style = false;
122
+
123
+ // Get array list of dismissed pointers for current user and convert it to array
124
+ $dismissed_pointers = explode( ',', get_user_meta( get_current_user_id(), 'dismissed_wp_pointers', true ) );
125
+
126
+ // Check if our pointer is not among dismissed ones
127
+ if ( !in_array( 'addtoany_settings_pointer', $dismissed_pointers ) ) {
128
+ $enqueue_pointer_script_style = true;
129
+
130
+ // Add footer scripts using callback function
131
+ add_action( 'admin_print_footer_scripts', 'A2A_SHARE_SAVE_pointer_print_scripts' );
132
+ }
133
+
134
+ // Enqueue pointer CSS and JS files, if needed
135
+ if ( $enqueue_pointer_script_style ) {
136
+ wp_enqueue_style( 'wp-pointer' );
137
+ wp_enqueue_script( 'wp-pointer' );
138
+ }
139
+
140
+ }
141
+ if ( !$A2A_SHARE_SAVE_options ) {
142
+ // Only show the pointer when no AddToAny options have been set
143
+ add_action( 'admin_enqueue_scripts', 'A2A_SHARE_SAVE_enqueue_pointer_script_style' );
144
+ }
145
+
146
+ function A2A_SHARE_SAVE_pointer_print_scripts() {
147
+
148
+ $pointer_content = '<h3>AddToAny Sharing Settings</h3>';
149
+ $pointer_content .= '<p>To customize your AddToAny share buttons, click &quot;AddToAny&quot; in the Settings menu.</p>';
150
+ ?>
151
+
152
+ <script type="text/javascript">
153
+ //<![CDATA[
154
+ jQuery(document).ready( function($) {
155
+ $('#menu-settings').pointer({
156
+ content: '<?php echo $pointer_content; ?>',
157
+ position: {
158
+ edge: 'left', // arrow direction
159
+ align: 'center' // vertical alignment
160
+ },
161
+ pointerWidth: 350,
162
+ close: function() {
163
+ $.post( ajaxurl, {
164
+ pointer: 'addtoany_settings_pointer', // pointer ID
165
+ action: 'dismiss-wp-pointer'
166
+ });
167
+ }
168
+ }).pointer('open');
169
+ });
170
+ //]]>
171
+ </script>
172
+
173
+ <?php
174
+ }
175
+
176
  function A2A_SHARE_SAVE_options_page() {
177
 
178
  global $A2A_SHARE_SAVE_plugin_url_path,
addtoany.services.php CHANGED
@@ -164,10 +164,6 @@ $A2A_SHARE_SAVE_services = Array(
164
  "name" => "Fark",
165
  "icon" => "fark",
166
  ),
167
- "favoriten" => Array(
168
- "name" => "Favoriten",
169
- "icon" => "favoriten",
170
- ),
171
  "flipboard" => Array(
172
  "name" => "Flipboard",
173
  "icon" => "flipboard",
@@ -192,18 +188,10 @@ $A2A_SHARE_SAVE_services = Array(
192
  "name" => "Google Gmail",
193
  "icon" => "gmail",
194
  ),
195
- "grono" => Array(
196
- "name" => "Grono",
197
- "icon" => "grono",
198
- ),
199
  "hatena" => Array(
200
  "name" => "Hatena",
201
  "icon" => "hatena",
202
  ),
203
- "hyves" => Array(
204
- "name" => "Hyves",
205
- "icon" => "hyves",
206
- ),
207
  "iwiw" => Array(
208
  "name" => "IWIW",
209
  "icon" => "iwiw",
164
  "name" => "Fark",
165
  "icon" => "fark",
166
  ),
 
 
 
 
167
  "flipboard" => Array(
168
  "name" => "Flipboard",
169
  "icon" => "flipboard",
188
  "name" => "Google Gmail",
189
  "icon" => "gmail",
190
  ),
 
 
 
 
191
  "hatena" => Array(
192
  "name" => "Hatena",
193
  "icon" => "hatena",
194
  ),
 
 
 
 
195
  "iwiw" => Array(
196
  "name" => "IWIW",
197
  "icon" => "iwiw",
icons/favoriten.png DELETED
Binary file
icons/grono.png DELETED
Binary file
icons/hyves.png DELETED
Binary file