Hi Bennn,
Sure thing. 🙂
The WordPress Codex actually has a great tutorial on how to develop a child theme.
I’d recommend giving this a read and letting us know, here, if you have follow-up questions. 🙂
http://codex.ww.wp.xz.cn/Child_Themes
Here is a very basic child theme for you StoreFront Starter Child Theme
Thread Starter
Bennn
(@bennn)
Hi Stuart,
Thank you so much. I used the code below in the child theme functions php but got this error message.
This is the uploaded child theme, I wanted to remove the footer credit and used this code on the forum:
<?php
/**
* storefront child theme functions.php file.
*
* @package storefront-child
*/
// DO NOT REMOVE THIS FUNCTION AS IT LOADS THE PARENT THEME STYLESHEET
add_action( ‘wp_enqueue_scripts’, ‘enqueue_parent_theme_style’ );
function enqueue_parent_theme_style() {
wp_enqueue_style( ‘parent-style’, get_template_directory_uri().’/style.css’ );
}
/* Add any custom PHP below this line of text */
add_action( ‘init’, ‘custom_remove_footer_credit’, 10 );
function custom_remove_footer_credit () {
remove_action( ‘storefront_footer’, ‘storefront_credit’, 20 );
add_action( ‘storefront_footer’, ‘custom_storefront_credit’, 20 );
}
function custom_storefront_credit() {
?>
<div class=”site-info”>
© <?php echo get_bloginfo( ‘name’ ) . ‘ ‘ . get_the_date( ‘Y’ ); ?>
</div><!– .site-info –>
<?php
}
This is the error message:
Parse error: syntax error, unexpected end of file in /home4/b2palace/public_html/fertil24.com/wp-content/themes/storefront-child/functions.php on line 28
What could have caused this and How do I remove error please.
Thank you.
Hi Bennn,
These kinds of errors (“unexpected end of file”) occur when the file hasn’t fully uploaded via FTP.
I’d advise re-uploading the “functions.php” file for the child theme and seeing if that resolves the error.
Thread Starter
Bennn
(@bennn)
Yes thank you so much, this has been resolved and i have started working on site again. Thanks all for supporting.