WordPress MU 2.7.1

WordPress MU is a multi user or multi blog version of WordPress that can be used to run sites like WordPress.com.

This release of WordPress MU has been much delayed but I think it’s been worth the wait. Included in this release are a number of new features and many bugfixes. Get it from the MU download page.

Update! In the final rush to get this post written I neglected to add that this release fixes a vulnerability in the importer system that would allow an untrusted user to run PHP code. Thanks to Alexander Concha for discovering the vulnerability and to Barry Abrahamson who recognised that some servers treat unknown file types as PHP scripts.
One more reason to upgrade.

New features and changes include:

  • A revamped plugin system thanks to Andy Peatling. Plugins installed in the plugins directory rather than mu-plugins can be activated and deactivated on all blogs with one click.
  • The admin bar was removed. It’ll be stuffed into a plugin instead. Must talk to Viper007Bond about that.
  • A new “My Blogs” page where a user’s blogs are listed and personal “per blog” settings can be configured. It’s empty right now but it’s easy to add settings to it via plugins. Imagine having a different “Display Name” on each blog you write on! See SetupMenu and HandleFormPOST in the just removed admin bar for example code. That code uses actions rather than filters but it’ll get you started.
  • The site admin can now set a Global Dashboard blog for users who don’t have blogs. Those users will be added to this blog rather than the main blog. The default role of users on that blog can also be set but if they’re not “Subscribers” they won’t be moved if you change the Global Dashboard.

They’re the major changes. Smaller changes include notification of failed blog upgrades [1728], MU will now ignore free space checks when importing posts [1725] and lots more. Check out the timeline for further details.

If you’re running WordPress MU 2.7 you can upgrade from inside the Dashboard. The system will notice that a new version is out and will lead you through the upgrade process, just like in regular WordPress. Plugins can be updated as well through the familiar plugin upgrade process as long as your plugins are hosted on the WordPress.org Plugins Database.

As always this release would not have been possible without the help and encouragement of many people along the way. I know I’ll leave out someone if I try to list everyone but I appreciate all the help people give working through tickets, and helping on the forums.

PS. WP Super Cache was updated today too. New features include an option to stop caching for logged in users, it doesn’t cache previewed posts, and it displays cache size summary information on the admin page now.
PPS. Happy birthday Adam! 2 today and Dad’s finally getting away from the computer now! πŸ™‚

WordPress MU 2.7.1 beta 2

WordPress MU is a multi user or multi blog version of WordPress that can be used to run sites like WordPress.com.

The 2.7.1 release is very close now. I have just uploaded wordpress-mu-2.7.1-beta2.zip for your enjoyment.

2.7.1 has taken longer than usual to come out, mainly because of the large number of bug fixes and new features in this release. Highlights include:

  • A revamped plugin system thanks to Andy Peatling. Plugins installed in the plugins directory rather than mu-plugins can be activated and deactivated on all blogs with one click.
  • The admin bar settings can be customized by any user for each blog via the “My Blogs” page. The code here is still rough, and may not make it into the final release. Please help clean it up!
  • The site admin can now set a Global Dashboard blog for users who don’t have blogs. Those users will be added to this blog rather than the first one.
  • And many more bugfixes you can read about on the MU Timeline

I think this release is just about good enough to put on a production server, but test it first on a development server and backup your old install if you’re really paranoid. All I’ll guarantee is that this software will take up space on your server. I need your help to test it.

If you’re a jQuery fiend or CSS styling guru, your help with the “My Blogs” page would be very much appreciated. My ugly code hides settings that aren’t relevant, but the page isn’t pretty. Use Trac or contact me through this site if you have ideas or code to contribute.

I’m glad to say that once MU 2.7.1 does come out. Upgrading from 2.7 should be as easy as clicking the Upgrade button in the dashboard. I tried upgrading from 2.7 yesterday and my test server upgraded itself after 1 or 2 false starts.
‘Course, if you’ve modified core files (naughty!), those changes will be overwritten and you’ll have to manually upgrade.

Thanks to everyone who helped me with patches, code snippets, ideas and with ticket updates on Trac.

Wireless Nunchuck Adapter Review

My latest gaming purchase last week was MadWorld for the Nintendo Wii Console. It’s a horribly violent and bloody beat-em-up and saw-em-up and gauge-em-up and .. you get the idea.
Everyone’s raving about it but after playing it for an hour or two I feared I’d snap my Nunchuck and Wiimote cable because one of the actions in the game calls for the player to err, snap the controls apart and something indescribable happens on screen. Someone loses their head, and they’re not angry! It certainly deserves the 18 cert,

Gameware Wireless Nunchuck Adapter Last weekend I popped into Game for a look around and spotted the Gameware Wireless Nunchuck Adapter for a reasonable €12.99. Not bad. I also bought a Wiimote charger but I’ll blog about that at a later stage. Can’t have too much excitement in one post now can we?

The box contained simple instructions, the adapter itself, and a small square transmitter/receiver you place on the end of the Wiimote (requiring a good tug to remove again!) It doesn’t include the Nunchuck. The adapter takes 2 AAA batteries. The Nunchuck fits snugly into the top, plugs in at the bottom, and the the cable is wound up at the back neatly. Press the little transmit button to connect it to the Wiimote and a little red light flashes on both.

Gameware Wireless Nunchucck Adapter

The first game I tried with it was Call of Duty, World at War (Get it! It’s a great game!) For the most part it’s fine and it’s neat not having the cable knocking against you as you play. If I can fault the adapter, I found that sometimes when pulling back on the Nunchuck joystick, the Nunchuck slid back slightly. It’s a snug fit, but could have done with some restraining plastic to hold things in place better.
Also, it you have overly large or small hands it might cause problems too but that’s a minor niggle.

MadWorld was more fun with the Wireless Adapter fitted to the Nunchuck. No worries about breaking cables any more! I still can’t recommend buying the game though. It got repetitive quickly, I spent my time bashing buttons desperately and wondering how I killed the end-of-level bosses.

MadWorld gets a thumbs down from me, but the Wireless Nunchuck Adapter from Game gets a thumbs up! πŸ™‚

The new Commodore 64 laptop

sx-64_build This isn’t the first time a Commodore 64 laptop has been made but it’s probably the coolest one. Commodore’s original SX 64 was built in 1984 and featured a tiny 5 inch CRT screen with a hardly portable body weighing in at 10kg!
I actually saw an SX 64 years ago in Cork Micro, the small computer shop run by the late Sean Bossang in Cork.
A couple of years ago there was the Picodore, a tiny little laptop built from the innards of a C64 DTV joystick. The keyboard’s a little small for my tastes though!
c64_hero And finally, Benjamin has created a real, “normal sized” laptop from the motherboard of a C64C, the final version of the C64 built by Commodore.
It uses the original keyboard too, and “1541-III DTV” to emulate the original 1541 disk drive. This device takes FAT32 formatted SD cards so you can copy D64 images from your PC on to it, insert the card in the laptop and load them immediately. Judging by the movie below, he needs an Action Replay cartridge or something to speed up loading. The emulated drive emulates the slow loading of the original drive too well methinks.

Nice to see Thunderblade make an appearance. I’m sure I have the original C64 tape of that game around here somewhere..

More info on Ben’s post.

Three links for WordPress developers

  • WordPress Coding Standards. I used to be a big fan of the “curly bracket on it’s own line” but many years ago that was beaten out of me. Coding standards can be a subjective preference, but they’re very useful when reading code created by others.
  • Data Validation. It’s vitally important that the data your web application accepts is checked for any malicious code. The new $wpdb->prepare() function is something every WordPress plugin author should be using if they have to use the database directly.
  • WordPress Nonces. A nonce makes sure that a request you’re sending your blog was one you meant to send. Without a nonce, another site could have your browser load an image on it’s site pointing at your blog’s admin page to do an administrative task. You don’t want another site fooling your browser into doing something malicious do you? See Cross-site request forgery on Wikipedia for more.

If you write plugins for WordPress, please take the time to read through those pages above and learn how to use the security tools on offer. I know of at least one very popular WordPress MU plugin that doesn’t use nonces and I’ve only looked at the code of a couple of them. Most plugins don’t use $wpdb->prepare() yet as it was only introduced in recent versions of WordPress.

As a user of Free Software, you already know that “Free” doesn’t mean “Free as in beer”, it’s “Free as in speech”. If you know anything about software development help plugin authors by looking over their shoulders and checking their code. There is a cost to everything. In Free Software that cost is helping to test or fix bugs in the software you value and enjoy.

PS. WordPress MU 2.7.1 beta 1 is out, as is WP Super Cache 0.9.3 which has even more fixes for those running the latest PHP5 builds. Bloody register_shutdown() and it’s object destruction caused me no end of grief debugging that.