Hi dicsuw,
witch base theme are you using for making child themes can you provide the link of wordpress theme
Thanks
Hi @dicsuw,
We can create a child theme following the very simple steps:
Create the folder with the name : “<parent-theme>-child” parallel to the parent theme folder.
Add a “style.css” file in it and add the following lines of code in it:
/*
Theme Name: <parent-theme> Child Theme
Theme URI: <theme-url>
Description: A child theme of <parent-theme>.
Author: <yourName>
Template: <parent_theme_folder_name>
Version: 1.0.0
*/
By doing this and saving the file, you’ll be able to see a child theme created in the “Appearance” section. Go there and activate it.
You can add your required files in your child theme like header.php, footer.php, functions.php, etc
Thanks!
Hi Dicky,
You can either set-up a child theme by following this guide:- https://codex.ww.wp.xz.cn/Child_Themes#Creating_a_Child_Theme_from_an_Unmodified_Parent_Theme
Or, you can download the pre-made blank child theme from theme author’s site:- http://wp-puzzle.com/docs/basic/where-to-get-a-child-theme.html
Hope it helps 🙂
Please try fowling step for making a wordpress child themes
/*
Theme Name: Twenty Fifteen Child ——-enter here name of your base theme——
Theme URI: http://example.com/twenty-fifteen-child/
Description: Twenty Fifteen Child Theme
Author: John Doe
Author URI: http://example.com
Template: twentyfifteen ———–enter your base theme name this is (mandatory)—–
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: light, dark, two-columns, right-sidebar, responsive-layout, accessibility-ready
Text Domain: twenty-fifteen-child
*/
@import url(‘../twentyfifteen/style.css’);
This is the one method to make a child theme in wordpress with style.css
and the second method to create child themes with function
<?php
// creating a function to add stylesheet
function twentyfifteen-child_add_parent_style() {
wp_enqueue_style( ‘twentyfifteen-style’, get_template_directory_uri() . ‘/style.css’, array() );
}
// add action name, function name
add_action( ‘wp_enqueue_scripts’, ‘twentyfifteen_add_parent_style’ );
/**
-
This reply was modified 9 years, 8 months ago by
oberoibunty.
Hi Suyogya
i am right or no i am also begener in wordpress community
Thanks
-
This reply was modified 9 years, 8 months ago by
oberoibunty.
Thread Starter
dicsuw
(@dicsuw)
Thanks for all of your guys advice. I would give try on it..
Regards,
Dicky
Hey @oberoibunty,
Please take a look at this link: https://codex.ww.wp.xz.cn/Child_Themes#Creating_a_Child_Theme_from_an_Unmodified_Parent_Theme
It’ll help you to set up a child theme and understand how it works 🙂