Dashboard Widget (Without Controls) Sample Plugin

WordPress 2.5 has the ability to customize your administration dashboard with the help of widgets.

After poking around WordPress 2.5 codes, I have come out with this Dashboard Widget Sample Plugin. BUT do note that this plugin does not include Dashboard Widget Controls. If I have the time, I will add that in or perhaps I will create another plugin called “Dashboard Widget (With Controls) Sample Plugin”.

To get a clearer picture of what this sample plugin does, here is a screenshot of the Dashboard Widget (Without Controls) Sample in action.

Here comes the code:

 'Full URL For "See All" link', // Example: 'index.php?page=wp-useronline/wp-useronline.php'
		'feed_link' => 'Full URL For "RSS" link', // Example: 'index.php?page=wp-useronline/wp-useronline-rss.php'
		'width' => 'half', // OR 'fourth', 'third', 'half', 'full' (Default: 'half')
		'height' => 'single', // OR 'single', 'double' (Default: 'single')
		)
	);
}

### Function: Add Dashboard Widget
add_filter('wp_dashboard_widgets', 'PLUGINNAME_add_dashboard_widget');
function PLUGINNAME_add_dashboard_widget($widgets) {
	global $wp_registered_widgets;
	if (!isset($wp_registered_widgets['dashboard_PLUGINNAME'])) {
		return $widgets;
	}
	array_splice($widgets, sizeof($widgets)-1, 0, 'dashboard_PLUGINNAME');
	return $widgets;
}

### Function: Print Dashboard Widget
function dashboard_PLUGINNAME($sidebar_args) {
	global $wpdb;
	extract($sidebar_args, EXTR_SKIP);
	echo $before_widget;
	echo $before_title;
	echo $widget_name;
	echo $after_title;
	echo 'YOUR CONTENT GOES IN HERE';
	echo $after_widget;
}
?>

Hope this helps some of you guys. =)

1 Star2 Stars3 Stars4 Stars5 Stars (33 votes, average: 3.91 out of 5)

Donations

Hi guys,

If you really like those plugins that I have created for WordPress and enjoy the fast support that I have given you whether it is through forums or email, perhaps you can consider dropping some donations to me =D

My Paypal email is gamerz84@hotmail.com, and my account now can accept credit card payment =D

Thank you so much =)

1 Star2 Stars3 Stars4 Stars5 Stars (602 votes, average: 3.90 out of 5)

WP-Downloads

I wonder if anybody is interested in this plugin which I think I may name it WP-Downloads. I ported it over from my WP 1.5.2 Site (http://www.lesterchan.net/blogs/) and modify it a little to be WP 2.0 friendly. What it does is basically add a little Download Section in your WordPress site. It will just keep track of how many times a file is downloaded. It will be a single page Download Section with categories to separate the files. I am still considering whether or not to add a upload feature to it as PHP only supports maximum 2MB of upload. Right now you have to upload the file to a directory set in the option page. I have not coded the user side yet, but the admin side is more or less done.

Give me your comments on this.

A similar demo is on http://www.lesterchan.net/others/downloads.php.
WP-Downloads Admin Screen

1 Star2 Stars3 Stars4 Stars5 Stars (333 votes, average: 3.90 out of 5)

5 Plugins Updated

I have updated 4 of my plugins.
WP-EMail 2.06
» FIXED: Modified Get Most Emailed Post Function
(Download | Documentation)

WP-PostRatings 1.03
» NEW: Total Rating Votes Stats And Total Rating Users Stats Function Added
» FIXED: Ratings Not Working On Physical Pages That Is Integrated Into WordPress
» FIXED: Modified Get Most/Highest Rated Post Function
» FIXED: Search Bots Unable To Index Site
(Download | Documentation)

WP-Stats 2.04
» NEW: Added Highest Rated Post If WP-PostRatings? Is Installed
» NEW: Remove My Other Plugins Stats Functions Inside stats.php
» NEW: WP-Stats Files Are Now In wp-content/plugins/stats/ Folder
» NEW: You Can Now Place Selected Stats On The Sidebar As A Widget
» NEW: Code That WP-Stats Generated Is XHTML 1.0 Transitional
(Download | Documentation)

WP-UserOnline 2.04
» NEW: Added Highest Rated Post If WP-PostRatings? Is Installed
» NEW: Remove My Other Plugins Stats Functions Inside stats.php
» NEW: WP-Stats Files Are Now In wp-content/plugins/stats/ Folder
» NEW: You Can Now Place Selected Stats On The Sidebar As A Widget
» NEW: Code That WP-Stats Generated Is XHTML 1.0 Transitional
(Download | Documentation)

WP-PostViews 1.01
» NEW: Added Get Total Views Function
» FIXED: Modified Get Most Viewed Post Function
(Download | Documentation)

1 Star2 Stars3 Stars4 Stars5 Stars (252 votes, average: 3.90 out of 5)

Ratings And Poll Updates

The targeted launch for WP-Polls 2.1 and WP-PostRatings 1.02 is 1st June 2006, as you can see now both will feature the fade in and fade out effect and the loading icon.

WP-Polls 2.1 will also feature a new option where you can choose to log by cookie, ip, both or none at all. I have updated the poll to log by cookie and ip, so now you can only vote once.

1 Star2 Stars3 Stars4 Stars5 Stars (244 votes, average: 3.90 out of 5)