admin管理员组

文章数量:1321047

I have a parent theme with 2 widget areas, header, sidebar, and footer, the header and the footer have 2 simple text widgets in them.

When I switch to the child theme which consists of just style.css and functions.php to enqueue the stylesheet, both the widgets are removed, they are also not in the inactive widgets area.

Is there a method for ensuring that the widgets are not lost when the themes are switched?

I have a parent theme with 2 widget areas, header, sidebar, and footer, the header and the footer have 2 simple text widgets in them.

When I switch to the child theme which consists of just style.css and functions.php to enqueue the stylesheet, both the widgets are removed, they are also not in the inactive widgets area.

Is there a method for ensuring that the widgets are not lost when the themes are switched?

Share Improve this question asked Dec 29, 2016 at 16:29 NazNaz 2114 silver badges13 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

I think you should check your parent theme functions.php for code which should load widgets and copy & paste such code to child theme functions.php file. It should work.

本文标签: Prevent widgets from disappearing when swtiching from parent to child theme