WordPress 2.5: How to display Technorati links on the dashboard?

So you’ve installed WordPress 2.5, now you want to show Technorati links on the dashboard. Here’s the code, that you can add in your functions.php or create a php file call it directly. The code will simply add the Technorati links in your exisiting dasboard layout. You can adjust CSS or make a widget out […]

So you’ve installed WordPress 2.5, now you want to show Technorati links on the dashboard. Here’s the code, that you can add in your functions.php or create a php file call it directly. The code will simply add the Technorati links in your exisiting dasboard layout. You can adjust CSS or make a widget out of it.

You may also like to read, "how to remove widgets from the dashboard?"

$defaultdata = array( 'til_links' => "10", ); add_action('activity_box_end', 'til'); function til() { global $defaultdata, $til_settings; if (!function_exists('MagpieRSS')) { // Check if another plugin is using RSS, may not work include_once (ABSPATH . WPINC . '/rss.php'); error_reporting(E_ERROR); } $home = get_option("home"); $rss = @fetch_rss('http://feeds.technorati.com/cosmos/rss/?url='.$home.'/'); if ( isset($rss->items) && 1 < count($rss->items) ) { // Technorati returns a 1-item feed when it has no results print '<h3>Technorati Links <cite><a href="http://www.technorati.com/search/'.$home.'?partner=wordpress">More &raquo;</a></cite></h3><ul>'; $til_links = 10; $rss->items = array_slice($rss->items, 0, $til_links); foreach ($rss->items as $item ) { $itemL = wp_filter_kses($item["link"]); $itemT = wptexturize(wp_specialchars($item["title"])); print '<li><a href="'.$itemL.'">'.$itemT.'</a></li>'; } print '</ul>'; } } //add_action('admin_footer', 'noff_warning'); function cd_remove() { remove_action( 'admin_head', 'index_js' ); } add_action( 'admin_print_scripts', 'cd_remove' ); function cd_incoming_links() {?> <script type="text/javascript"> jQuery(function() { jQuery('#incominglinks').load('index-extra.php?jax=incominglinks');}); </script> <?php } if ( basename( $_server['script_filename'] ) ="=" 'index.php' ) { add_action( 'admin_head', 'cd_incoming_links' ); } function cd_css() { ?> <style type="text/css" media="screen">#zeitgeist { float: right; width: 70%; }#zeitgeist div { float: left; width: 31%; margin-bottom: 20px; margin-right: 3%; }#zeitgeist div + div + div { margin-right: 0; }#zeitgeist div + div + div + div { float: none; width: 100%; margin-bottom: 0; }#zeitgeist h3 { font-size: 14px; }#zeitgeist li { list-style: none; }#zeitgeist ul { margin-left: 0; padding-left: 0; }#zeitgeist h3 { clear: both; }</style> <?php } add_action( 'admin_head', 'cd_css' );

Note: I think, I got this code from some plugin. Thanks to the coder.

WordPress, WordPress 2.5, Brecker, Technorati, Links, How To, Tips, Tips and Tricks, Tricks, PHP

About The Author

Deepak Gupta is a IT & Web Consultant. He is the founder and CEO of diTii.com & DIT Technologies, where he's engaged in providing Technology Consultancy, Design and Development of Desktop, Web and Mobile applications using various tools and softwares. Sign-up for the Email for daily updates. Google+ Profile.