Follow these steps to prepare the environment for this recipe:
- Open a code editor and make sure you have access to the plugin files of your WordPress installation.
- Create a custom plugin for this chapter's code by using the instructions from the Working with custom PHP codes recipe in Chapter 3, Using Plugins and Widgets. We will name the plugin WPCookbook Chapter 7 within the wpcookbookchapter7.php file.
- Once created, activate the plugin by using the backend plugins list.