Hi, themeco
I am trying to add custom HTML to your themes from my functions.php
Which hook would I hook onto to accomplish this?
Thanks
Hi, themeco
I am trying to add custom HTML to your themes from my functions.php
Which hook would I hook onto to accomplish this?
Thanks
Hi There @wmmajaliwa
Thanks for writing in! First you will need to setup a child theme and activate it by following our guide here (https://theme.co/apex/forum/t/setup-how-to-setup-child-themes/57).
Then you can place your code into your child theme’s functions.php file. Follow the example below.
// Add HTML after body tag
function my_custom_html() {
?>
<h1>My HTML </h1>
<?php
}
add_action('x_before_site_begin', 'my_custom_html');
Hope that helps.
This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.