Allows you to set and display your social media profiles in your public forum profile. As administrator, you can select which sites will be supported using simple management panel.
bbPress plugin browser »
bbSocialize (0.0.3)
Average Rating





Your Rating
Author: F.Thion
-
It's very early release, supporting Twitter, StumbleUpon, Digg, Pownce, Flickr and Delicious - if you want to see more websites supported, don't hesitate to contact me - via my blog, or here in comments, and I will implement more social media sites.
Posted: 3 months ago # -
Hello,
please add technorati and mybloglog :p
so, see at the socialble wordpress plugin: http://wordpress.org/extend/plugins/sociable/ ;)
bye
Posted: 3 months ago # -
I'm liking this idea, haven't tried it yet. Can you add FaceBook, MySpace, etc.?
Posted: 3 months ago # -
Technorati, MyBlogLog, Facebook, MySpace - anything else? I should release 0.0.3 next week.
Posted: 3 months ago # -
hello,
where the icons is displayed when the profil is completed?
it is possible to show icones under the avatar? or under the <?php post_author_title_link(); ?> ?
i have a new proposition: http://presence.jabberfr.org/ this service show a icon when you are online or offline in jabber :) so, no icons need, because the link is: http://presence.jabberfr.org/5b898e12c9602b98859b89643ac1e68f/image-default.png for me for example :p it is possible to add this? :)
bye
Posted: 3 months ago # -
It would be possible, but I have to code few additional lines of code (read: added to my TO DO list). And I think that current architecture of the plugin will turn your bbPress into worse server-killer than phpBB2 by Przemo lol. So I guess if I'm going to do this, then not sooner than in v1.0 because I will have to strongly optimize the code (and I don't have budget for that yet).
As for jabber - maybe in v2.0 :P
Posted: 3 months ago # -
hi Thion,
i try to add:
add_action('get_profile_info_keys','get_socialize');
at the end of the plugin.So, in the profile page, i have this error:
Catchable fatal error: Object of class stdClass could not be converted to string in forum/bb-includes/backpress/functions.core.php on line 156why?
bye.
Posted: 3 months ago # -
I'm sure this is 1.0 Alpha, right? This might be an issue of Backpress, but I will have to look into code today. But if I may ask - why do you need this:
add_action('get_profile_info_keys','get_socialize');If you're trying to display profiles buttons in posts, then know that 0.0.3 have already this function so just be patient and I will upload it soon ;)
Posted: 3 months ago # -
hi,
there are no profiles buttons in posts with the 0.0.3 :(
++
Posted: 2 months ago # -
Make sure you have set up images url in management panel, but without final slash. Also, make sure you have put proper function within post.php file in your template (see readme for more details).
Posted: 2 months ago # -
i do that but i have only a
<div class="socialize_wrap"></div>
displayed in source code :/Posted: 2 months ago # -
Are you sure you are using correct function? As the code you showed is displayed in profile page only, in posts should be
<div class="post_socialize_wrap">- see readme to make sure you're using the correct function, functions for profile page and posts are two different things.Posted: 2 months ago # -
oh yes, i have corrected and put get_socialize_post in posts :p
so, i have an error in posts:
Missing argument 1 for get_socialize_post(), called in /home/toto/forum/bb-templates/strapontins2/post.php on line 9 and defined in /home/toto/forum/bb-plugins/bbsocialize/bb-socialize.php on line 245
line 245 is:
function get_socialize_post( $user_id ) {
++
Posted: 2 months ago # -
I think I will have to update readme a little - you have to put the following code into your post.php file:
get_socialize_post( get_post_author_id() );Otherwise it won't work.
Posted: 2 months ago # -
I want to thank Thion for this plugin. I wanted to use it and have support for the social networks I use most so, I went ahead and played with the plugin and added support for plurk, myspace and facebook. I will be adding support for the sites some you asked for like mybloglog and stumbleupon, plus a bunch of others as soon as I get more free time.
Here is the updated code for the bb-socialize.php file
-------Code Begin------<?php /* Plugin Name: bbSocialize Description: Allows you to set and display your social media websites link in your profile. Plugin URI: http://astateofmind.eu/freebies/bbsocialize Author: F.Thion Author URI: http://astateofmind.eu Version: 0.0.3 license: CC-GNU-GPL http://creativecommons.org/licenses/GPL/2.0/ donate: http://astateofmind.eu/about/support/ TO DO: - Add support for - Technorati - MyBlogLog - MySpace History for 0.0.3: - If profiles are empty and are not set by user, then they are not displayed; - Added support for technorati; - Changed images names, from x.gif to bb_x.gif; - Minor modifications to look of management page; - Added support to display profile links in single posts; - Added "Reset Button" - you can now reset all settings to default (minor error, changes won't appear without page refresh) */ function bb_socialize_initialize() { global $bb, $bb_current_user, $bb_socialize, $bb_signatures_type; if ( !isset( $bb_socialize ) ) { $bb_socialize = bb_get_option('bb_socialize'); if ( !$bb_socialize ) { $bb_socialize['minimum_user_level'] = "participate"; $bb_socialize['images_url'] = bb_get_option('uri'); $bb_socialize['links_rel'] = "nofollow"; $bb_socialize['plurk'] = "true"; $bb_socialize['twitter'] = "true"; $bb_socialize['pownce'] = "true"; $bb_socialize['facebook'] = "true"; $bb_socialize['myspace'] = "true"; $bb_socialize['flickr'] = "true"; $bb_socialize['delicious'] = "true"; $bb_socialize['digg'] = "true"; $bb_socialize['technorati'] = "true"; } } } add_action( 'bb_init', 'bb_socialize_initialize'); // Let's get some profiles to display function get_plurk($user_id) { $user = bb_get_user( $user_id ); $bb_plurk = $user->social_plurk; if ( $bb_plurk ) { return $bb_plurk; } else { return ""; } } function get_twitter($user_id) { $user = bb_get_user( $user_id ); $bb_twitter = $user->social_twitter; if ( $bb_twitter ) { return $bb_twitter; } else { return ""; } } function get_pownce($user_id) { $user = bb_get_user( $user_id ); $bb_pownce = $user->social_pownce; if ( $bb_pownce ) { return $bb_pownce; } else { return ""; } } function get_facebook($user_id) { $user = bb_get_user( $user_id ); $bb_facebook = $user->social_facebook; if ( $bb_facebook ) { return $bb_facebook; } else { return ""; } } function get_myspace($user_id) { $user = bb_get_user( $user_id ); $bb_myspace = $user->social_myspace; if ( $bb_myspace ) { return $bb_myspace; } else { return ""; } } function get_flickr($user_id) { $user = bb_get_user( $user_id ); $bb_flickr = $user->social_flickr; if ( $bb_flickr ) { return $bb_flickr; } else { return ""; } } function get_delicious($user_id) { $user = bb_get_user( $user_id ); $bb_delicious = $user->social_delicious; if ( $bb_delicious ) { return $bb_delicious; } else { return ""; } } function get_digg($user_id) { $user = bb_get_user( $user_id ); $bb_digg = $user->social_digg; if ( $bb_digg ) { return $bb_digg; } else { return ""; } } function get_technorati($user_id) { $user = bb_get_user( $user_id ); $bb_technorati = $user->social_technorati; if ( $bb_technorati ) { return $bb_technorati; } else { return ""; } } // Now, let's add input fields to our profile-edit page function add_socialize_to_profile_edit() { global $user_id, $bb_current_user, $bb_socialize; if (bb_current_user_can($bb_socialize['minimum_user_level']) && bb_is_user_logged_in() ) : $bb_plurk = get_plurk($user_id); $bb_twitter = get_twitter($user_id); $bb_pownce = get_pownce($user_id); $bb_facebook = get_facebook($user_id); $bb_myspace = get_myspace($user_id); $bb_flickr = get_flickr($user_id); $bb_delicious = get_delicious($user_id); $bb_digg = get_digg($user_id); $bb_technorati = get_technorati($user_id); echo '<div class="socialize_edit"> <fieldset> <legend>'. __('Social Media Profiles') .'</legend> <p>Set your Social Media Profiles below.</p> <table>'; if ( $bb_socialize['plurk'] == true ) { echo '<tr class="form-field"> <th scope="row">Plurk</th> <td> <input type="text" name="bb_plurk" value="'. $bb_plurk .'" /> </td> </tr>'; } if ( $bb_socialize['twitter'] == true ) { echo '<tr class="form-field"> <th scope="row">Twitter</th> <td> <input type="text" name="bb_twitter" value="'. $bb_twitter .'" /> </td> </tr>'; } if ( $bb_socialize['pownce'] == true ) { echo '<tr class="form-field"> <th scope="row">Pownce</th> <td> <input type="text" name="bb_pownce" value="'. $bb_pownce .'" /> </td> </tr>'; } if ( $bb_socialize['facebook'] == true ) { echo '<tr class="form-field"> <th scope="row">Facebook Account #</th> <td> <input type="text" name="bb_facebook" value="'. $bb_facebook .'" /> </td> </tr>'; } if ( $bb_socialize['myspace'] == true ) { echo '<tr class="form-field"> <th scope="row">MySpace</th> <td> <input type="text" name="bb_myspace" value="'. $bb_myspace .'" /> </td> </tr>'; } if ( $bb_socialize['flickr'] == true ) { echo '<tr class="form-field"> <th scope="row">Flickr</th> <td> <input type="text" name="bb_flickr" value="'. $bb_flickr .'" /> </td> </tr>'; } if ( $bb_socialize['delicious'] == true ) { echo '<tr class="form-field"> <th scope="row">Delicious</th> <td> <input type="text" name="bb_delicious" value="'. $bb_delicious .'" /> </td> </tr>'; } if ( $bb_socialize['digg'] == true ) { echo '<tr class="form-field"> <th scope="row">Digg</th> <td> <input type="text" name="bb_digg" value="'. $bb_digg .'" /> </td> </tr>'; } if ( $bb_socialize['technorati'] == true ) { echo '<tr class="form-field"> <th scope="row">Technorati</th> <td> <input type="text" name="bb_technorati" value="'. $bb_technorati .'" /> </td> </tr>'; } echo '</table></fieldset> </div>'; endif; } add_action('extra_profile_info', 'add_socialize_to_profile_edit'); // The following function can be used to display profiles on user-profile-page function get_socialize() { global $user_id, $bb_current_user, $bb_socialize; $user_id = bb_get_user( $user_id ); $bb_plurk = $user_id->social_plurk; $bb_twitter = $user_id->social_twitter; $bb_facebook = $user_id->social_facebook; $bb_myspace = $user_id->social_myspace; $bb_flickr = $user_id->social_flickr; $bb_pownce = $user_id->social_pownce; $bb_delicious = $user_id->social_delicious; $bb_digg = $user_id->social_digg; $bb_technorati = $user_id->social_technorati; echo '<div class="socialize_wrap">'; if ( $bb_socialize['plurk'] == true ) { if ( !empty( $bb_plurk ) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_plurk.png" width="16" height="16" border="0" /><a href="http://plurk.com/'.$bb_plurk.'" title="User Plurk account" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_plurk.'</span></a></dd>'; } } if ( $bb_socialize['twitter'] == true ) { if ( !empty( $bb_twitter ) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_twitter.png" width="16" height="16" border="0" /><a href="http://twitter.com/'.$bb_twitter.'" title="User Twitter account" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_twitter.'</span></a></dd>'; } } if ( $bb_socialize['pownce'] == true ) { if ( !empty( $bb_pownce ) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_pownce.png" width="16" height="16" border="0" /><a href="http://pownce.com/'.$bb_pownce.'" title="User Pownce account" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_pownce.'</span></a></dd>'; } } if ( $bb_socialize['facebook'] == true ) { if ( !empty( $bb_facebook ) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_facebook.png" width="16" height="16" border="0" /><a href="http://www.facebook.com/profile.php?id='.$bb_facebook.'" title="User Facebook account" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_facebook.'</span></a></dd>'; } } if ( $bb_socialize['myspace'] == true ) { if ( !empty( $bb_myspace ) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_myspace.png" width="16" height="16" border="0" /><a href="http://myspace.com/'.$bb_myspace.'" title="User MySpace page" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_myspace.'</span></a></dd>'; } } if ( $bb_socialize['flickr'] == true ) { if ( !empty( $bb_flickr ) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_flickr.png" width="16" height="16" border="0" /><a href="http://flickr.com/photos/'.$bb_flickr.'" title="User Flickr account" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_flickr.'</span></a></dd>'; } } if ( $bb_socialize['delicious'] == true ) { if ( !empty( $bb_delicious ) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_delicious.png" width="16" height="16" border="0" /><a href="http://delicious.com/'.$bb_delicious.'" title="User Delicious account" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_delicious.'</span></a></dd>'; } } if ( $bb_socialize['digg'] == true ) { if ( !empty( $bb_digg ) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_digg.png" width="16" height="16" border="0" /><a href="http://digg.com/users/'.$bb_digg.'" title="User Digg account" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_digg.'</span></a></dd>'; } } if ( $bb_socialize['technorati'] == true ) { if ( !empty( $bb_technorati) ) { echo '<dd><img src="'.$bb_socialize['images_url'].'/bb_technorati.png" width="16" height="16" border="0" /><a href="http://technorati.com/people/technorati/'.$bb_technorati.'" title="User Technorati account" rel="'.$bb_socialize['links_rel'].'"><span>'.$bb_technorati.'</span></a></dd>'; } } echo '</div>'; } // The following function can be used in posts; just put get_socialize_post(get_post_author_id()); somewhere :) function get_socialize_post( $user_id ) { global $bb, $bb_socialize; $user_id = bb_get_user( $user_id ); $bb_plurk = $user_id->social_plurk; $bb_twitter = $user_id->social_twitter; $bb_pownce = $user_id->social_pownce; $bb_facebook = $user_id->social_facebook; $bb_myspace = $user_id->social_myspace; $bb_flickr = $user_id->social_flickr; $bb_delicious = $user_id->social_delicious; $bb_digg = $user_id->social_digg; $bb_technorati = $user_id->social_technorati; echo '<div class="post_socialize_wrap">'; if ( $bb_socialize['plurk'] == true ) { if ( !empty( $bb_plurk ) ) { echo '<span><a href="http://plurk.com/'.$bb_plurk.'" title="User Plurk account" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_plurk.png" width="16" height="16" border="0" /></a></span>'; } } if ( $bb_socialize['twitter'] == true ) { if ( !empty( $bb_twitter ) ) { echo '<span><a href="http://twitter.com/'.$bb_twitter.'" title="User Twitter account" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_twitter.png" width="16" height="16" border="0" /></a></span>'; } } if ( $bb_socialize['pownce'] == true ) { if ( !empty( $bb_pownce ) ) { echo '<span><a href="http://pownce.com/'.$bb_pownce.'" title="User Pownce account" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_pownce.png" width="16" height="16" border="0" /></a></span>'; } } if ( $bb_socialize['facebook'] == true ) { if ( !empty( $bb_facebook ) ) { echo '<span><a href="http://www.facebook.com/profile.php?id='.$bb_facebook.'" title="User Facebook account" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_facebook.png" width="16" height="16" border="0" /></a></span>'; } } if ( $bb_socialize['myspace'] == true ) { if ( !empty( $bb_myspace ) ) { echo '<span><a href="http://myspace.com/'.$bb_myspace.'" title="User MySpace page" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_myspace.png" width="16" height="16" border="0" /></a></span>'; } } if ( $bb_socialize['flickr'] == true ) { if ( !empty( $bb_flickr ) ) { echo '<span><a href="http://flickr.com/photos/'.$bb_flickr.'" title="User Flickr account" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_flickr.png" width="16" height="16" border="0" /></a></span>'; } } if ( $bb_socialize['delicious'] == true ) { if ( !empty( $bb_delicious ) ) { echo '<span><a href="http://delicious.com/'.$bb_delicious.'" title="User Delicious account" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_delicious.png" width="16" height="16" border="0" /></a></span>'; } } if ( $bb_socialize['digg'] == true ) { if ( !empty( $bb_digg ) ) { echo '<span><a href="http://digg.com/users/'.$bb_digg.'" title="User Digg account" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_digg.png" width="16" height="16" border="0" /></a></span>'; } } if ( $bb_socialize['technorati'] == true ) { if ( !empty( $bb_technorati) ) { echo '<span><a href="http://technorati.com/people/technorati/'.$bb_technorati.'" title="User Technorati account" rel="'.$bb_socialize['links_rel'].'"><img src="'.$bb_socialize['images_url'].'/bb_technorati.png" width="16" height="16" border="0" /></a></span>'; } } echo '</div>'; } function update_user_socialize() { global $user_id, $bb_socialize; $bb_plurk = $_POST['bb_plurk']; $bb_twitter = $_POST['bb_twitter']; $bb_pownce = $_POST['bb_pownce']; $bb_facebook = $_POST['bb_facebook']; $bb_myspace = $_POST['bb_myspace']; $bb_flickr = $_POST['bb_flickr']; $bb_delicious = $_POST['bb_delicious']; $bb_digg = $_POST['bb_digg']; $bb_technorati = $_POST['bb_technorati']; if ( $bb_plurk ) { $bb_plurk = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_plurk) ), true) ) ); bb_update_usermeta($user_id, "social_plurk",$bb_plurk); } else {bb_delete_usermeta($user_id, "social_plurk");} if ( $bb_twitter ) { $bb_twitter = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_twitter) ), true) ) ); bb_update_usermeta($user_id, "social_twitter",$bb_twitter); } else {bb_delete_usermeta($user_id, "social_twitter");} if ( $bb_pownce ) { $bb_pownce = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_pownce) ), true) ) ); bb_update_usermeta($user_id, "social_pownce",$bb_pownce); } else {bb_delete_usermeta($user_id, "social_pownce");} if ( $bb_facebook ) { $bb_facebook = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_facebook) ), true) ) ); bb_update_usermeta($user_id, "social_facebook",$bb_facebook); } else {bb_delete_usermeta($user_id, "social_facebook");} if ( $bb_myspace ) { $bb_myspace = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_myspace) ), true) ) ); bb_update_usermeta($user_id, "social_myspace",$bb_myspace); } else {bb_delete_usermeta($user_id, "social_myspace");} if ( $bb_flickr ) { $bb_flickr = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_flickr) ), true) ) ); bb_update_usermeta($user_id, "social_flickr",$bb_flickr); } else {bb_delete_usermeta($user_id, "social_flickr");} if ( $bb_delicious ) { $bb_delicious = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_delicious) ), true) ) ); bb_update_usermeta($user_id, "social_delicious",$bb_delicious); } else {bb_delete_usermeta($user_id, "social_delicious");} if ( $bb_digg ) { $bb_digg = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_digg) ), true) ) ); bb_update_usermeta($user_id, "social_digg",$bb_digg); } else {bb_delete_usermeta($user_id, "social_digg");} if ( $bb_technorati ) { $bb_technorati = bb_filter_kses( stripslashes( balanceTags( bb_code_trick( bb_encode_bad($bb_technorati) ), true) ) ); bb_update_usermeta($user_id, "social_technorati",$bb_technorati); } else {bb_delete_usermeta($user_id, "social_technorati");} } add_action('profile_edited', 'update_user_socialize'); function bb_socialize_admin_page() { global $bb_socialize; ?> <h2>bbPress Social Profiles Management</h2> <form method="post" name="bb_socialize_form" id="bb_socialize_form"> <fieldset> <input type="hidden" name="bb_socialize" value="1"> <table class="widefat"> <thead> <tr><th width="170">Option</th><th>Setting</th></tr> </thead> <tbody> <tr> <td><label for="images_url"><b>URL to images</b></label></td> <td> <input type="text" name="images_url" class="text long" value="<?php echo $bb_socialize['images_url']; ?>"> Please provide full url, but without final slash. </td> </tr> <tr> <td><label for="links_rel"><b>Links REL</b></label></td> <td> <input type="text" name="links_rel" class="text long" value="<?php echo $bb_socialize['links_rel']; ?>"> e.g. follow </td> </tr> </tbody> </table> <h3>Set social sites</h3> <p>Use the settings below to decide, which social media websites will be used on your forum. Set "yes" if you want to allow users to set their account for this specific website, or set "no" to hide the specific website. You can change these settings anytime you want.</p> <table class="widefat"> <thead> <tr><th width="170">Social Media Site</th><th>Display</th></tr> </thead> <tbody> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_plurk.png" width="16" height="16" border="0" /> <label for="plurk"><b>Plurk</b></label></td> <td> <input name="plurk" value="1" type="radio" <?php if ( $bb_socialize['plurk'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="plurk" value="0" type="radio" <?php if ( $bb_socialize['plurk'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_twitter.png" width="16" height="16" border="0" /> <label for="twitter"><b>Twitter</b></label></td> <td> <input name="twitter" value="1" type="radio" <?php if ( $bb_socialize['twitter'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="twitter" value="0" type="radio" <?php if ( $bb_socialize['twitter'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_pownce.png" width="16" height="16" border="0" /> <label for="pownce"><b>Pownce</b></label></td> <td> <input name="pownce" value="1" type="radio" <?php if ( $bb_socialize['pownce'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="pownce" value="0" type="radio" <?php if ( $bb_socialize['pownce'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_facebook.png" width="16" height="16" border="0" /> <label for="facebook"><b>Facebook</b></label></td> <td> <input name="facebook" value="1" type="radio" <?php if ( $bb_socialize['facebook'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="facebook" value="0" type="radio" <?php if ( $bb_socialize['facebook'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_myspace.png" width="16" height="16" border="0" /> <label for="myspace"><b>MySpace</b></label></td> <td> <input name="myspace" value="1" type="radio" <?php if ( $bb_socialize['myspace'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="myspace" value="0" type="radio" <?php if ( $bb_socialize['myspace'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_flickr.png" width="16" height="16" border="0" /> <label for="flickr"><b>Flickr</b></label></td> <td> <input name="flickr" value="1" type="radio" <?php if ( $bb_socialize['flickr'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="flickr" value="0" type="radio" <?php if ( $bb_socialize['flickr'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_delicious.png" width="16" height="16" border="0" /> <label for="delicious"><b>Delicious</b></label></td> <td> <input name="delicious" value="1" type="radio" <?php if ( $bb_socialize['delicious'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="delicious" value="0" type="radio" <?php if ( $bb_socialize['delicious'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_digg.png" width="16" height="16" border="0" /> <label for="digg"><b>Digg</b></label></td> <td> <input name="digg" value="1" type="radio" <?php if ( $bb_socialize['digg'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="digg" value="0" type="radio" <?php if ( $bb_socialize['digg'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> <tr> <td><img src="<?php echo $bb_socialize['images_url']; ?>/bb_technorati.png" width="16" height="16" border="0" /> <label for="technorati"><b>Technorati</b></label></td> <td> <input name="technorati" value="1" type="radio" <?php if ( $bb_socialize['technorati'] == true ) { echo 'checked="checked"'; } ?>> Yes <input name="technorati" value="0" type="radio" <?php if ( $bb_socialize['technorati'] == false ) { echo 'checked="checked"'; } ?>>No </td> </tr> </tbody> </table> <p class="submit"><input type="submit" name="bb_socialize_submit" value="Save bbSocialize settings"> <input type="submit" name="bb_socialize_reset" value="Reset settings"></p> </fieldset> </form> <hr /> <p>If you like this plugin, please donate few bucks so I could keep developing it. Or at least <a href="http://twitter.com/t_thion/">follow me on Twitter</a> :). <form action="https://www.paypal.com/cgi-bin/webscr" method="post"> <input type="hidden" name="cmd" value="_donations"> <input type="hidden" name="business" value="wojciech.usarzewicz@gmail.com"> <input type="hidden" name="item_name" value="bbPages Donation"> <input type="hidden" name="item_number" value="bbPages Donation"> <input type="hidden" name="no_shipping" value="0"> <input type="hidden" name="no_note" value="1"> <input type="hidden" name="currency_code" value="USD" /> Type donation amount: $ <input type="text" name="amount" value="1" /> <input type="hidden" name="tax" value="0"> <input type="hidden" name="lc" value="US"> <input type="hidden" name="bn" value="PP-DonationsBF"> <input type="submit" name="submit" value="Donate with PayPal!" alt="PayPal - The safer, easier way to pay online!"> <img alt="" border="0" src="https://www.paypal.com/pl_PL/i/scr/pixel.gif" width="1" height="1"> </form> </p> <?php } function bb_socialize_process_post() { if ( isset( $_POST['bb_socialize_submit'] ) && isset( $_POST['bb_socialize'] ) ) { global $bb_socialize; foreach( array_keys($bb_socialize) as $key) { if ( isset( $_POST[$key] ) ) { $bb_socialize[$key] = $_POST[$key]; } } bb_update_option('bb_socialize',$bb_socialize); } elseif ( isset( $_POST['bb_socialize_reset'] ) ) { global $bb_socialize; foreach( array_keys($bb_socialize) as $key) { if ( isset( $_POST[$key] ) ) { $bb_socialize[$key] = $_POST[$key]; } } bb_delete_option('bb_socialize'); } } add_action( 'bb_admin-header.php','bb_socialize_process_post'); function bb_socialize_add_admin_page() { bb_admin_add_submenu(__('Social Profiles'), 'administrate', 'bb_socialize_admin_page' ); } add_action( 'bb_admin_menu_generator', 'bb_socialize_add_admin_page' ); ?>-------End Code ------
Works great on my site.
Thanks again Thion.
Posted: 2 days ago #
Add a Comment
You must log in to post.