What is a Child Theme?
Child themes are WordPress themes that inherit the functionality, features, and style of the parent theme. It is then possible to customize the child theme without making changes to the parent theme.
Why Use a Child Theme?
There are a few reasons why you would want to use a child theme:
- A child theme is a quick and efficient way to customize your WordPress site.
- If you modify a theme directly and it is updated, your modifications will be lost. By using a child theme you will ensure that your modifications are preserved.
- Using a child theme can speed up development time.
- Using a child theme is a great way to learn about WordPress theme development.
Create a Child Theme
If you used the Theme Setup Wizard a child theme has already been created and activated for you automatically, unless you skipped that step in the process then follow the steps below.
-
- Go into your WordPress Admin
- Appearance > Theme Setup
- Click Start
- Click Install (if you already have a child theme it’ll notify you and you can just click “Return to Dashboard”)
- Once that’s complete, click “Return to Dashboard”
- Happy Editing!
Find any CSS property, Quickly & Easily
A theme can contain thousands of CSS properties, a super quick and easy way to find what controls what is using your browser’s built-in developer tools. Once you learn how to leverage this you’ll be saying “How did I ever get along without this in the past!”.
- Open your site in your favorite browser, like Google Chrome 😉
- Find the element you’d like to modify
- Right-click > Inspect Element
- You’ll notice a new pane open in the bottom of your browser window
- One with Source Code and the other CSS
- Copy your changed properties to Real Estate 7 Options > Custom CSS or to your child themes style.css
- That’s it!
Overwriting Images in your Child Theme
You can also overwrite images via your child theme, for instance changing the colors of the map pins.
- Access your site via FTP using a program like FileZilla
- Navigate to your WordPress installation
- Find wp-content > themes > your-child-theme-name
- Copy the /images/ folder from the parent theme to your child theme keeping the same structure
- Go back on to your computer find where you saved the main download
- Find the “psd” folder > open map-pins.psd
- Make your modifications
- Select the slices
- File > Export > Quick Export as PNG or File > Save for Web > Select the slices
- Upload those images into your child themes > images folder via FTP
- Refresh your site and you should see your newly modified map pins
If you don’t copy the entire images folder from the parent theme to the child theme (step 4) you will end up with 404s (missing images) throughout your website.