Simple SVN WordPress Widget
After getting bored on working on my final year project I decided to take a look at creating widgets word my blog. There are SVN hooks on my repositories that store the commit details in a SQL database. I thought I would create a widget that would pull out the last message and display it.
/* Plugin Name: LastCommit Plugin URI: http://blog.yeticode.co.uk/ Description: Gets Last Commit Message Author: John Tindell Version: 1 Author URI: http://blog.yeticode.co.uk/ */ function lastCommit_widget() { $server = 'localhost'; $link = mssql_connect($server, 'username', '************'); echo ''; } function init_lastCommit(){ register_sidebar_widget("LastCommit", "lastCommit_widget"); } add_action("plugins_loaded", "init_lastCommit");
When I get more time I will develop this a bit more.
Glenn Bennett 3:26 pm on April 9, 2009 Permalink |
John,
I would be easy to make the widget a bit more theme friendly by using my new tool over at widgetifyr.com.
If you get a chance to try it please let me know what you think.
Glenn