Divi: Child Theme configuration standard

Written By Shane Taubman

August 2, 2018

Based on :https://www.elegantthemes.com/blog/divi-resources/divi-child-theme

Steps

  1. Login to elegant themes website and download latest Divi Theme with builder version.
  2. Upload zipped ‘Divi’ WordPress theme
  3. Configure username and API key for ‘Divi’ theme
  4. Create Divi “Child” Theme
  5. Edit Style.css
  6. Edit Functions.php
  7. Add Screenshot.png

Divi Child Theme

  • Open web hosting cPanel or File Manager
  • Browse to \wp-content\themes\
  • Create folder ‘divi-child’

Configure Divi-Child Theme Folder

  • Create the following files and folders in the ‘divi-child’ folder
    • style.css
    • functions.php

Style.css

Edit style.css and add the following syntax then save file.

/*
Theme Name:     Divi Child Theme
Theme URI:      https://www.elegantthemes.com/gallery/divi/
Description:    Divi Child Theme
Author:         Elegant Themes
Author URI:     https://www.elegantthemes.com
Template:       Divi
Version:        1.0.0
*/
 
/* =Theme customization starts here
------------------------------------------------------- */

Functions.php

Enqueue your parent and child theme stylesheets.

  • First must get Enqueue syntax from Divi Parent Theme
  • Using File Manager browse to \wp-content\themes\divi
    • View / Edit functions.php
    • Search for the following
      • wp_enqueue_style()
        • It should be followed with get_stylesheet_uri()
        • Confirm the style name which in most cases is called “divi-style”
        • Using File Manager browse to \wp-content\themes\divi-child
          • Edit functions.php and add the following syntax then save file.
<?php
function my_theme_enqueue_styles() {
 
$parent_style = 'divi-style';
 
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' );
?>

Screenshot (Thumbnail)

Upload screenshot.png to \wp-content\themes\divi-child

Activate Theme

Navigate to Appearance > Themes

  • Click Activate on Divi Child Theme.

More modifications.

More coming soon…..

You may also like…

Google: MyBusiness

Google: MyBusiness

Requirements Google Account created for SEO or business e-mail address. Setup Google My Business...

read more

0 Comments