Can't find header info in order to change it

I opened the header.php file in order to copy it into my child theme to make some edits, but the only thing in the header file is the following line of code:

<?php x_get_view( 'header', 'base' ); ?>

Where can I find all of the code that the header is pulling in?

I looked into this more and it seems as though I’m supposed to go to frameworks > views > icon (this is the stack i’m using)

I did this, but I still don’t see a header file. And when I do find the header files, what kind of folder/file path do I need to put into my child theme in order to edit it?

Hi there,

Thanks for writing in.

It should be under this file \framework\legacy\cranium\headers\views\icon\wp-header.php and \framework\legacy\cranium\headers\views\global\_header.php. Or \framework\views\header\base.php, but it’s mostly the legacy templates depending on which is active. You may do trial and error to see what template should behave, it’s added like that for backward compatibility which may also change in the future.

Thanks!

Three header files is really confusing. I need to add code from Facebook to the header.php file to monetize my instant articles and trial and error really isn’t working because they have too much of a delay.

Hi there,

If it’s just adding to the header, then you don’t need to edit those templates, just add this to your child theme’s functions.php with your facebook embed code

add_action('wp_head', 'facebook_code');

function facebook_code () { ?>

<!-- facebook code begins here -->

<!-- facebook code ends here -->

<?php }

Hope this helps.

1 Like