Version Description
- Fixed the xhtml validation issues
- 'target=blank' (open link in new window) issue solved
- Sprites can now be disabled, allowing for custom icons
- Sprites have been disabled for RSS
- You can now deactivate the blogplay widget from your wordpress dashboard
Download this release
Release Info
| Developer | sociable |
| Plugin | |
| Version | 3.5.1 |
| Comparing to | |
| See all releases | |
Code changes from version 3.5.0 to 3.5.1
- images/addtofavorites.png +0 -0
- images/blogplay.png +0 -0
- readme.txt +8 -2
- sociable.php +51 -24
images/addtofavorites.png
ADDED
|
Binary file
|
images/blogplay.png
ADDED
|
Binary file
|
readme.txt
CHANGED
|
@@ -3,7 +3,7 @@ Contributors: sociable
|
|
| 3 |
Tags: social, bookmark, bookmarks, bookmarking, social bookmarking, social bookmarks, blogplay
|
| 4 |
Requires at least: 2.6
|
| 5 |
Tested up to: 2.8.4
|
| 6 |
-
Stable tag: 3.5.
|
| 7 |
|
| 8 |
Automatically add links on your posts, pages and RSS feed to your favorite social bookmarking sites.
|
| 9 |
|
|
@@ -22,8 +22,14 @@ More info:
|
|
| 22 |
|
| 23 |
== Changelog ==
|
| 24 |
|
| 25 |
-
= 3.5.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 26 |
|
|
|
|
| 27 |
* The icons now load in a CSS Sprites, allowing for faster download times.
|
| 28 |
* These services have been discontinued: BlogMeme FR, BlogMeme SP, co.mments, DesignFloat.com, PPNow.net, Symbaloo.com.
|
| 29 |
* You can now add links to your browser favorites.
|
| 3 |
Tags: social, bookmark, bookmarks, bookmarking, social bookmarking, social bookmarks, blogplay
|
| 4 |
Requires at least: 2.6
|
| 5 |
Tested up to: 2.8.4
|
| 6 |
+
Stable tag: 3.5.1
|
| 7 |
|
| 8 |
Automatically add links on your posts, pages and RSS feed to your favorite social bookmarking sites.
|
| 9 |
|
| 22 |
|
| 23 |
== Changelog ==
|
| 24 |
|
| 25 |
+
= 3.5.1 =
|
| 26 |
+
* Fixed the xhtml validation issues
|
| 27 |
+
* 'target=blank' (open link in new window) issue solved
|
| 28 |
+
* Sprites can now be disabled, allowing for custom icons
|
| 29 |
+
* Sprites have been disabled for RSS
|
| 30 |
+
* You can now deactivate the blogplay widget from your wordpress dashboard
|
| 31 |
|
| 32 |
+
= 3.5.0 =
|
| 33 |
* The icons now load in a CSS Sprites, allowing for faster download times.
|
| 34 |
* These services have been discontinued: BlogMeme FR, BlogMeme SP, co.mments, DesignFloat.com, PPNow.net, Symbaloo.com.
|
| 35 |
* You can now add links to your browser favorites.
|
sociable.php
CHANGED
|
@@ -3,7 +3,7 @@
|
|
| 3 |
Plugin Name: Sociable
|
| 4 |
Plugin URI: http://blogplay.com/plugin
|
| 5 |
Description: Automatically add links on your posts, pages and RSS feed to your favorite social bookmarking sites.
|
| 6 |
-
Version: 3.5.
|
| 7 |
Author: Blogplay
|
| 8 |
Author URI: http://blogplay.com/
|
| 9 |
|
|
@@ -483,7 +483,7 @@ $sociable_known_sites = Array(
|
|
| 483 |
|
| 484 |
'Sphinn' => Array(
|
| 485 |
'favicon' => 'sphinn.png',
|
| 486 |
-
'url' => 'http://sphinn.com/index.php?c=post&m=submit&link=PERMALINK',
|
| 487 |
'spriteCoordinates' => Array(199,55),
|
| 488 |
),
|
| 489 |
|
|
@@ -614,14 +614,14 @@ $sociable_known_sites = Array(
|
|
| 614 |
),
|
| 615 |
|
| 616 |
'Add to favorites' => Array(
|
| 617 |
-
'favicon' => '',
|
| 618 |
'url' => 'javascript:AddToFavorites();',
|
| 619 |
'spriteCoordinates' => Array(181,73),
|
| 620 |
'supportsIframe' => false,
|
| 621 |
),
|
| 622 |
|
| 623 |
'Blogplay' => Array(
|
| 624 |
-
'favicon' => '',
|
| 625 |
'url' => 'http://blogplay.com',
|
| 626 |
'spriteCoordinates' => Array(199,73),
|
| 627 |
'supportsIframe' => false,
|
|
@@ -774,20 +774,20 @@ function sociable_html($display=array()) {
|
|
| 774 |
*/
|
| 775 |
$link .= '<a ';
|
| 776 |
$link .= ($sitename=="Blogplay") ? '' : 'rel="nofollow"';
|
| 777 |
-
$link .= ' id="'.esc_attr(strtolower($sitename)).'"';
|
| 778 |
/**
|
| 779 |
* Use the iframe option if it is enabled and supported by the service/site
|
| 780 |
*/
|
| 781 |
if (get_option('sociable_useiframe') && !isset($site['supportsIframe'])) {
|
| 782 |
$iframeWidth = get_option('sociable_iframewidth',900);
|
| 783 |
$iframeHeight = get_option('sociable_iframeheight',500);
|
| 784 |
-
$link .= 'class="thickbox" href="' . $url . "?TB_iframe=true&height=$iframeHeight&width=$iframeWidth\">";
|
| 785 |
} else {
|
| 786 |
-
if(
|
| 787 |
if (get_option('sociable_usetargetblank')) {
|
| 788 |
$link .= " target=\"_blank\"";
|
| 789 |
}
|
| 790 |
-
$link .= " href=\"".$url."
|
| 791 |
} else {
|
| 792 |
$link .= " href=\"$url\" title=\"$description\">";
|
| 793 |
}
|
|
@@ -803,14 +803,14 @@ function sociable_html($display=array()) {
|
|
| 803 |
/**
|
| 804 |
* If site doesn't have sprite information
|
| 805 |
*/
|
| 806 |
-
if (!isset($site['spriteCoordinates'])) {
|
| 807 |
if (strpos($site['favicon'], 'http') === 0) {
|
| 808 |
$imgsrc = $site['favicon'];
|
| 809 |
} else {
|
| 810 |
$imgsrc = $imagepath.$site['favicon'];
|
| 811 |
}
|
| 812 |
$link .= "<img src=\"".$imgsrc."\" title=\"$description\" alt=\"$description\"";
|
| 813 |
-
$link .= (!get_option('sociable_disablealpha',false)) ? " class=\"sociable-hovers
|
| 814 |
/**
|
| 815 |
* If site has sprite information use it
|
| 816 |
*/
|
|
@@ -818,12 +818,15 @@ function sociable_html($display=array()) {
|
|
| 818 |
$imgsrc = $imagepath."services-sprite.gif";
|
| 819 |
$services_sprite_url = $imagepath . "services-sprite.png";
|
| 820 |
$spriteCoords = $site['spriteCoordinates'];
|
| 821 |
-
$link .= "<img src=\"".$imgsrc."\" title=\"$description\" alt=\"$description\" style=\"background: transparent url($services_sprite_url) no-repeat; background-position:-$spriteCoords[0]px -$spriteCoords[1]px\"";
|
| 822 |
-
$link .= (!get_option('sociable_disablealpha',false)) ? " class=\"sociable-hovers
|
| 823 |
}
|
| 824 |
-
if (isset($site['class']) && $site['class'])
|
| 825 |
-
$link .= " sociable_{$site['class']}";
|
| 826 |
-
|
|
|
|
|
|
|
|
|
|
| 827 |
}
|
| 828 |
$link .= "</a></li>";
|
| 829 |
|
|
@@ -920,19 +923,25 @@ function sociable_restore_config($force=false) {
|
|
| 920 |
if ( $force OR !( get_option('sociable_usecss') ) )
|
| 921 |
update_option('sociable_usecss', true);
|
| 922 |
|
| 923 |
-
if ( $force or !( get_option('sociable_iframewidth')))
|
| 924 |
-
{
|
| 925 |
update_option('sociable_iframewidth',900);
|
| 926 |
}
|
| 927 |
-
if ( $force or !( get_option('sociable_iframeheight')))
|
| 928 |
-
{
|
| 929 |
update_option('sociable_iframeheight',500);
|
| 930 |
}
|
| 931 |
|
| 932 |
-
if ( $force or !( get_option('sociable_disablealpha')))
|
| 933 |
-
{
|
| 934 |
update_option('sociable_disablealpha',false);
|
| 935 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 936 |
}
|
| 937 |
|
| 938 |
/**
|
|
@@ -1079,7 +1088,7 @@ function sociable_submenu() {
|
|
| 1079 |
delete_option('sociable_active_sites', $active_sites);
|
| 1080 |
add_option('sociable_active_sites', $active_sites);
|
| 1081 |
|
| 1082 |
-
foreach ( array('usetargetblank', 'useiframe', 'disablealpha', 'awesmenable', 'usecss', 'usetextlinks') as $val ) {
|
| 1083 |
if ( isset($_POST[$val]) && $_POST[$val] )
|
| 1084 |
update_option('sociable_'.$val,true);
|
| 1085 |
else
|
|
@@ -1193,6 +1202,14 @@ function sociable_submenu() {
|
|
| 1193 |
<input type="hidden" id="site_order" name="site_order" value="<?php echo join('|', array_keys($sociable_known_sites)) ?>" />
|
| 1194 |
</td>
|
| 1195 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1196 |
<tr>
|
| 1197 |
<th scope="row" valign="top">
|
| 1198 |
<?php _e("Disable alpha mask on share toolbar?", "sociable"); ?>
|
|
@@ -1287,6 +1304,14 @@ function sociable_submenu() {
|
|
| 1287 |
<?php _e("awe.sm API Key:", 'sociable'); ?> <input size="65" type="text" name="awesmapikey" value="<?php echo get_option('sociable_awesmapikey'); ?>" />
|
| 1288 |
</td>
|
| 1289 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1290 |
<tr>
|
| 1291 |
<td> </td>
|
| 1292 |
<td>
|
|
@@ -1345,7 +1370,7 @@ function sociable_filter_plugin_actions( $links, $file ){
|
|
| 1345 |
add_filter( 'plugin_action_links', 'sociable_filter_plugin_actions', 10, 2 );
|
| 1346 |
|
| 1347 |
/**
|
| 1348 |
-
* Add the
|
| 1349 |
*/
|
| 1350 |
if (!function_exists('blogplay_db_widget')) {
|
| 1351 |
function blogplay_text_limit( $text, $limit, $finish = ' […]') {
|
|
@@ -1396,6 +1421,8 @@ if (!function_exists('blogplay_db_widget')) {
|
|
| 1396 |
wp_add_dashboard_widget( 'blogplay_db_widget' , 'The Latest news from BlogPlay.Com' , 'blogplay_db_widget');
|
| 1397 |
}
|
| 1398 |
|
| 1399 |
-
|
|
|
|
|
|
|
| 1400 |
}
|
| 1401 |
?>
|
| 3 |
Plugin Name: Sociable
|
| 4 |
Plugin URI: http://blogplay.com/plugin
|
| 5 |
Description: Automatically add links on your posts, pages and RSS feed to your favorite social bookmarking sites.
|
| 6 |
+
Version: 3.5.1
|
| 7 |
Author: Blogplay
|
| 8 |
Author URI: http://blogplay.com/
|
| 9 |
|
| 483 |
|
| 484 |
'Sphinn' => Array(
|
| 485 |
'favicon' => 'sphinn.png',
|
| 486 |
+
'url' => 'http://sphinn.com/index.php?c=post&m=submit&link=PERMALINK',
|
| 487 |
'spriteCoordinates' => Array(199,55),
|
| 488 |
),
|
| 489 |
|
| 614 |
),
|
| 615 |
|
| 616 |
'Add to favorites' => Array(
|
| 617 |
+
'favicon' => 'addtofavorites.png',
|
| 618 |
'url' => 'javascript:AddToFavorites();',
|
| 619 |
'spriteCoordinates' => Array(181,73),
|
| 620 |
'supportsIframe' => false,
|
| 621 |
),
|
| 622 |
|
| 623 |
'Blogplay' => Array(
|
| 624 |
+
'favicon' => 'blogplay.png',
|
| 625 |
'url' => 'http://blogplay.com',
|
| 626 |
'spriteCoordinates' => Array(199,73),
|
| 627 |
'supportsIframe' => false,
|
| 774 |
*/
|
| 775 |
$link .= '<a ';
|
| 776 |
$link .= ($sitename=="Blogplay") ? '' : 'rel="nofollow"';
|
| 777 |
+
$link .= ' id="'.esc_attr(strtolower(str_replace(" ", "", $sitename))).'" ';
|
| 778 |
/**
|
| 779 |
* Use the iframe option if it is enabled and supported by the service/site
|
| 780 |
*/
|
| 781 |
if (get_option('sociable_useiframe') && !isset($site['supportsIframe'])) {
|
| 782 |
$iframeWidth = get_option('sociable_iframewidth',900);
|
| 783 |
$iframeHeight = get_option('sociable_iframeheight',500);
|
| 784 |
+
$link .= 'class="thickbox" href="' . $url . "?TB_iframe=true&height=$iframeHeight&width=$iframeWidth\">";
|
| 785 |
} else {
|
| 786 |
+
if(!($sitename=="Add to favorites")) {
|
| 787 |
if (get_option('sociable_usetargetblank')) {
|
| 788 |
$link .= " target=\"_blank\"";
|
| 789 |
}
|
| 790 |
+
$link .= " href=\"".$url."\" title=\"$description\">";
|
| 791 |
} else {
|
| 792 |
$link .= " href=\"$url\" title=\"$description\">";
|
| 793 |
}
|
| 803 |
/**
|
| 804 |
* If site doesn't have sprite information
|
| 805 |
*/
|
| 806 |
+
if (!isset($site['spriteCoordinates']) || get_option('sociable_disablesprite',false) || is_feed()) {
|
| 807 |
if (strpos($site['favicon'], 'http') === 0) {
|
| 808 |
$imgsrc = $site['favicon'];
|
| 809 |
} else {
|
| 810 |
$imgsrc = $imagepath.$site['favicon'];
|
| 811 |
}
|
| 812 |
$link .= "<img src=\"".$imgsrc."\" title=\"$description\" alt=\"$description\"";
|
| 813 |
+
$link .= (!get_option('sociable_disablealpha',false)) ? " class=\"sociable-hovers" : "";
|
| 814 |
/**
|
| 815 |
* If site has sprite information use it
|
| 816 |
*/
|
| 818 |
$imgsrc = $imagepath."services-sprite.gif";
|
| 819 |
$services_sprite_url = $imagepath . "services-sprite.png";
|
| 820 |
$spriteCoords = $site['spriteCoordinates'];
|
| 821 |
+
$link .= "<img src=\"".$imgsrc."\" title=\"$description\" alt=\"$description\" style=\"width: 16px; height: 16px; background: transparent url($services_sprite_url) no-repeat; background-position:-$spriteCoords[0]px -$spriteCoords[1]px\"";
|
| 822 |
+
$link .= (!get_option('sociable_disablealpha',false)) ? " class=\"sociable-hovers" : "";
|
| 823 |
}
|
| 824 |
+
if (isset($site['class']) && $site['class']) {
|
| 825 |
+
$link .= (!get_option('sociable_disablealpha',false)) ? " sociable_{$site['class']}\"" : " class=\"sociable_{$site['class']}\"";
|
| 826 |
+
} else {
|
| 827 |
+
$link .= (!get_option('sociable_disablealpha',false)) ? "\"" : "";
|
| 828 |
+
}
|
| 829 |
+
$link .= " />";
|
| 830 |
}
|
| 831 |
$link .= "</a></li>";
|
| 832 |
|
| 923 |
if ( $force OR !( get_option('sociable_usecss') ) )
|
| 924 |
update_option('sociable_usecss', true);
|
| 925 |
|
| 926 |
+
if ( $force or !( get_option('sociable_iframewidth'))) {
|
|
|
|
| 927 |
update_option('sociable_iframewidth',900);
|
| 928 |
}
|
| 929 |
+
if ( $force or !( get_option('sociable_iframeheight'))) {
|
|
|
|
| 930 |
update_option('sociable_iframeheight',500);
|
| 931 |
}
|
| 932 |
|
| 933 |
+
if ( $force or !( get_option('sociable_disablealpha'))) {
|
|
|
|
| 934 |
update_option('sociable_disablealpha',false);
|
| 935 |
}
|
| 936 |
+
|
| 937 |
+
if ( $force or !( get_option('sociable_disablesprite')) ) {
|
| 938 |
+
update_option('sociable_disablesprite',false);
|
| 939 |
+
}
|
| 940 |
+
|
| 941 |
+
if ( $force or !( get_option('sociable_disablewidget')) ) {
|
| 942 |
+
update_option('sociable_disablewidget',false);
|
| 943 |
+
}
|
| 944 |
+
|
| 945 |
}
|
| 946 |
|
| 947 |
/**
|
| 1088 |
delete_option('sociable_active_sites', $active_sites);
|
| 1089 |
add_option('sociable_active_sites', $active_sites);
|
| 1090 |
|
| 1091 |
+
foreach ( array('usetargetblank', 'useiframe', 'disablealpha', 'disablesprite', 'awesmenable', 'usecss', 'usetextlinks', 'disablewidget') as $val ) {
|
| 1092 |
if ( isset($_POST[$val]) && $_POST[$val] )
|
| 1093 |
update_option('sociable_'.$val,true);
|
| 1094 |
else
|
| 1202 |
<input type="hidden" id="site_order" name="site_order" value="<?php echo join('|', array_keys($sociable_known_sites)) ?>" />
|
| 1203 |
</td>
|
| 1204 |
</tr>
|
| 1205 |
+
<tr>
|
| 1206 |
+
<th scope="row" valign="top">
|
| 1207 |
+
<?php _e("Disable sprite usage for images?", "sociable"); ?>
|
| 1208 |
+
</th>
|
| 1209 |
+
<td>
|
| 1210 |
+
<input type="checkbox" name="disablesprite" <?php checked( get_option('sociable_disablesprite'), true ) ; ?> />
|
| 1211 |
+
</td>
|
| 1212 |
+
</tr>
|
| 1213 |
<tr>
|
| 1214 |
<th scope="row" valign="top">
|
| 1215 |
<?php _e("Disable alpha mask on share toolbar?", "sociable"); ?>
|
| 1304 |
<?php _e("awe.sm API Key:", 'sociable'); ?> <input size="65" type="text" name="awesmapikey" value="<?php echo get_option('sociable_awesmapikey'); ?>" />
|
| 1305 |
</td>
|
| 1306 |
</tr>
|
| 1307 |
+
<tr>
|
| 1308 |
+
<th scope="row" valign="top">
|
| 1309 |
+
<?php _e("Disable Blogplay's widget from dashboard:", "sociable"); ?>
|
| 1310 |
+
</th>
|
| 1311 |
+
<td>
|
| 1312 |
+
<input type="checkbox" name="disablewidget" <?php checked( get_option('sociable_disablewidget'), true ); ?> />
|
| 1313 |
+
</td>
|
| 1314 |
+
</tr>
|
| 1315 |
<tr>
|
| 1316 |
<td> </td>
|
| 1317 |
<td>
|
| 1370 |
add_filter( 'plugin_action_links', 'sociable_filter_plugin_actions', 10, 2 );
|
| 1371 |
|
| 1372 |
/**
|
| 1373 |
+
* Add the Blogplay.com RSS feed to the WordPress dashboard
|
| 1374 |
*/
|
| 1375 |
if (!function_exists('blogplay_db_widget')) {
|
| 1376 |
function blogplay_text_limit( $text, $limit, $finish = ' […]') {
|
| 1421 |
wp_add_dashboard_widget( 'blogplay_db_widget' , 'The Latest news from BlogPlay.Com' , 'blogplay_db_widget');
|
| 1422 |
}
|
| 1423 |
|
| 1424 |
+
if (!get_option('sociable_disablewidget',false)) {
|
| 1425 |
+
add_action('wp_dashboard_setup', 'blogplay_widget_setup');
|
| 1426 |
+
}
|
| 1427 |
}
|
| 1428 |
?>
|
