I’ve been following WP plugin development-related news for a week or two now, and I’ve noticed something that could make creating a plugin easier – plugin generators. These tools can create a handy template for your new plugin so you don’t need to start completely from scratch; you still need to know (at least) PHP to make your plugin do anything useful, though.
In this post I’ll review three WordPress plugin generators I’ve come across.
This is a primitive WP plugin that can take the information you supply and write the standard WordPress plugin header to a new file in your wp-content/plugins directory. You can then use the WP’s built-in plugin editor to add some functionality to the newly created plugin. Not that I know why anyone would want to do it this way – with the built-in editor you have no syntax highlighting and no handy keyboard shortcuts (personally, I just can’t live without Ctrl-S).
Strangely enough, this thing got nearly 500 votes on Digg. I guess most of the voters weren’t developers at all.
This is definitely the best plugin generator I’ve seen to date. It can generate decently structured, object-oriented plugins. It can also create stub methods for handling various WordPress filters, hooks and actions. Other features include database support, the possibility to add a widget to the plugin, adding admin menus, localization support and more.
What more can I say? Well, you still need to be knowledgeable about WP plugin development and PHP to make good use of the features. And it’s in “beta”. And there are too many steps in the generation process (it would probably be possible to condense some steps to a single screen). Overall, it’s still good 😛
Just for completeness, here’s another plugin generator – the aptly named WP Plugin Generator. It looks a bit outdated, but supports some common plugin features, like adding something before/after posts and handling plugin-specific <!–tags–>. It’s also simpler than the Fun With Plugins generator, so may be worth a look.
If you’re a WP plugin developer, or looking to create your first plugin, you might also find the WordPress Plugin Framework project interesting.Related posts :