I wrote a thing, and then I wrote about the thing I wrote.
I also sent an email to the IDL, because I thought they might think it was cool and a linkback to the WP.org page might help spread the word and make it easier for WordPress users (and there are a lot of us) to participate without having to hack our themes, and (not to toot my own horn or anything) it was apparently pretty well-received.
How many times have you wanted to display a sitewide notification on your site? I’ve needed it a lot on a variety of sites, and the plugins I’ve found in the repository left much to be desired. I decided to create my own, which is still in development, that I plan on uploading to WordPress.org. It’s called, unoriginally, Notifications, and you can grab it here.
This plugin requires the use of the
body_open hook in your theme. If your theme doesn’t support it, you’ll need to add it. I didn’t know about this hook but I will start adding hooks to various places in Museum Core in the future, starting with this. It was first proposed on Trac as a way to do exactly what I needed to do, which is display something right after the
<body> tag opens.
To use the notifications, add
<?php do_action( 'body_open' ); ?> to your theme, then create a new notification from the notifications page.
Right now, it just has a really simple dark background with light text. I plan on adding an options page where there can be “themes” as well as (possibly) a custom css panel to add your own styles. I’m also going to add internationalization support.
I’ve had this plugin installed on a number of my sites for a while now. It’s not much, in fact, it was my very first plugin, ever. I finally decided to upload it to the WordPress.org repository. I’m talking, of course, of my Hello Dolly fork, Hello Ziggy. All it does is adds a bit of lyric from “Ziggy Stardust” and adds it to your dashboard screen. However, I haven’t touched it in years, and with the restructuring of the WordPress admin in the last couple major revisions, it was way out of place, expecting a much bigger header. I decided to finally fix up the CSS a bit and, while I was at it, made a GitHub repo and added it to WordPress.org. It’s just as relevant (and, arguably, as inspiring) as the “Hello Dolly” lyrics, and who can beat opening up your dashboard to this?