In “Automating WordPress customizations – the plugin way” we looked at how to change a whole bunch of thing in one go by having our own plugin. The plugin approach can save a lot of time, but it does not actually give any control over the installation process.
Often we want to interfere with the way things are. For example, upon successful WordPress installation you find a web site with one post (“Hello World!”), one page (“About”), and a test comment to the first post. Also, there is a category “Uncategorized”, and “admin” user, and a few other things in the database, which are not so obvious (for example, user roles, such as Administrator, Editor, and Subscriber).
There are also a few things, which are happening during the installation process itself. For example, a random password for the administrator is generation, and email is sent to the administrator’s address with credentials and new site details. As handy as it is for a friend’s new blog, there are many situations when we don’t want this done, or want it done differently.
WordPress has a way to control installation flow via a custom install.php file, which saves you from all the problems of core files editing. In this post, we’ll see how to use this feature and what can actually be done with it.
Read the rest of this entry »