WordPress child theme question

WordPress: 4.2.2
Theme: Divi (latest version)

Hi. I am building a WordPress child theme, and have a couple of questions -- grateful for any advice.

* I am following the instructions here: http://codex.wordpress.org/Child_Themes

* I have created a folder called Divi-child, and placed a simple style.css file in that folder, following the instructions from WordPress codex.

* I am not sure what to put in the functions.php file. Should I use simply the recommended PHP code as follows?

function theme_enqueue_styles() {

    $parent_style = 'parent-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 )
add_action( 'wp_enqueue_scripts', 'theme_enqueue_styles' );

Open in new window

Thank you for any advice!

best from Eric
Eric BourlandAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Jason C. LevineDon't talk to me.Commented:
You don't need to put anything in the functions.php file to enqueue the style.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Eric BourlandAuthor Commented:
Jason, good to hear from you, as always. =)

Do you mean I can just exclude / omit / skip the functions.php file altogether?

Jason C. LevineDon't talk to me.Commented:
Depends on what you need the child theme to do.

In the child theme, functions.php is additive to the parent theme.  So the parent's functions are fully available to the child.  All you need to add are functions that are specific to the child.
Fundamentals of JavaScript

Learn the fundamentals of the popular programming language JavaScript so that you can explore the realm of web development.

Eric BourlandAuthor Commented:
I understand.

My only purpose in setting up this Divi-child child theme is, the client wants me to make some small modifications to the appearance of his web site. So I thought I would start by making this child theme. The modifications are indeed minor -- adding a twitter hashtag; adding a photo and a link in the header.

So, I will accomplish these tasks by modifying the style sheet -- and, I assume I will modify the new style.css style sheet that I have put in the /Divi-child/ folder, correct?

Will I need to tell functions.php to utilize style.css in the /Divi-child/ folder?

Thank you again for helping me to understand.

Jason C. LevineDon't talk to me.Commented:
Yes, modify the style sheet in the child theme.  No, you will not need to tell the theme anything, it is already looking at the child theme.
Eric BourlandAuthor Commented:
Jason, thank you as always for your patient help. =) Take care. Hope your summer is going great.

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.