Site logo

Archived topic

Child theme not working after site migration

6 replies · Started by Ashton on October 30, 2017

Viewing posts 1–7 of 7

Hello I just migrated my site from localhost and the child theme won't work it says it needs the parent theme installed, but I've reinstalled the parent theme half-a-dozen times and it still won't work

Here is what my functions.php file looks like:

*/

<?php
function my_theme_enqueue_styles() {

$parent_style = 'parent-style'; // This is 'generate-style' for the GeneratePress theme.

wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' );
wp_enqueue_style( 'child-style',
get_stylesheet_directory_uri() . '/style.css',
array( $parent_style ),
wp_get_theme()->get('Version')
);
}
add_action( 'wp_enqueue_scripts', 'my_theme_enqueue_styles' );
?>

/*

It didn't, I'm not exactly sure what should be in that document after removing code that looks like the one mentioned in that article.

Yes, I will copy the custom coding into this thank you!

No problem!

This archived topic is closed to new replies.