• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 679
  • Last Modified:

WordPress Child Theme Not Working

I just created a child theme for our self-hosted WordPress blog. The site never used a child theme previously but I want to avoid it being overwritten as updates to the theme come out. The parent theme is twentyeleven.

So I followed the instructions on the WordPress Codex site to create a child theme:

1.  Created a folder in my wp-content/themes folder called twentyeleven-child.
2.  Added a style.css file to this folder.
3.  Added the following css code to the child style.css file:

 Theme Name:     Twenty Eleven Child
 Theme URI:      http://mysite.org/twentyeleven-child/
 Description:    Twenty Eleven Child Theme
 Author:         My name
 Author URI:     http://mysite.org/
 Template:       twentyeleven

/* =Imports styles from the parent theme
-------------------------------------------------------------- */
@import url('../twentyeleven/style.css');

/* =Theme customization starts here
-------------------------------------------------------------- */

4. Returned to WordPress and activated the child theme.

When I activate the child theme it shows the original twentyeleven design (colors, featured image, sidebar, etc.), and not the customized version we have been using as a parent theme for the past two years??

What am I missing? If my customized parent theme based on the twentyeleven theme works, then why doesn't it show the same design theme when set up as a child theme using the style.css file listed above?
  • 2
1 Solution
Jason C. LevineNo oneCommented:
Many of the customizations are stored in the wp-options table and are specific to the active theme. So by switching to a new theme, even a child theme, you lose those option settings and thus the customizations that go with them.

You will just need to reset them.
kenjpeteAuthor Commented:
Ok, can I copy/paste those customized fields in the wp-options table from the parent theme to the child theme? I have access to that database via phpMyAdmin.
Jason C. LevineNo oneCommented:
You can try...may not work as expected and I don't have a list of all the different key-value pairs that you would need to modify so it would be a lot of trial and error.

Child Themes are best applied at the beginning of the process...applying one mid-stream will involve recreating menus, widgets, headers, and potentially custom CSS.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now