[{"data":1,"prerenderedAt":407},["ShallowReactive",2],{"page:\u002Fdocumentation\u002Fchild-theme-basics\u002F":3},{"id":4,"title":5,"body":6,"dateModified":391,"datePublished":392,"description":393,"extension":394,"heroAlt":395,"heroImage":396,"layout":397,"meta":398,"navigation":205,"ogDescription":400,"ogImage":396,"ogTitle":401,"path":402,"schema":403,"seo":404,"stem":405,"__hash__":406},"content\u002Fdocumentation\u002Fchild-theme-basics.md","Child Theme Basics",{"type":7,"value":8,"toc":382},"minimark",[9,13,16,21,24,41,44,48,63,67,78,150,167,170,174,184,237,247,257,292,298,302,314,318,321,332,335,339,360,378],[10,11,12],"p",{},"When you want to change how Blaskan looks or behaves, editing the theme files directly is tempting but creates a problem: the next time Blaskan updates, your changes are overwritten. A child theme solves this. It is a separate theme folder that inherits everything from Blaskan (the parent theme) and lets you override only what you need to change. Updates to Blaskan do not touch the child theme folder.",[10,14,15],{},"This page covers the minimum structure required to create a Blaskan child theme and the most common customizations.",[17,18,20],"h2",{"id":19},"what-a-child-theme-consists-of","What a Child Theme Consists Of",[10,22,23],{},"A child theme only needs two files to work:",[25,26,27,35],"ul",{},[28,29,30,34],"li",{},[31,32,33],"code",{},"style.css"," with the required header comment",[28,36,37,40],{},[31,38,39],{},"functions.php"," to enqueue the parent theme's styles",[10,42,43],{},"Everything else is optional. You add template files only when you need to override a specific template.",[17,45,47],{"id":46},"creating-the-child-theme-directory","Creating the Child Theme Directory",[10,49,50,51,54,55,58,59,62],{},"In your WordPress installation, navigate to ",[31,52,53],{},"wp-content\u002Fthemes\u002F",". Create a new folder. The convention is to name it after the parent theme with ",[31,56,57],{},"-child"," appended. For Blaskan, a reasonable name is ",[31,60,61],{},"blaskan-child",".",[17,64,66],{"id":65},"the-stylecss-header","The style.css Header",[10,68,69,70,73,74,77],{},"Inside ",[31,71,72],{},"blaskan-child\u002Fstyle.css",", the file must open with a specific comment block. WordPress reads this comment to identify the theme. The key line is ",[31,75,76],{},"Template:"," which tells WordPress which parent theme to use.",[79,80,85],"pre",{"className":81,"code":82,"language":83,"meta":84,"style":84},"language-css shiki shiki-themes github-light github-dark","\u002F*\n Theme Name:   Blaskan Child\n Theme URI:    https:\u002F\u002Fyoursite.com\n Description:  A child theme for Blaskan\n Author:       Your Name\n Author URI:   https:\u002F\u002Fyoursite.com\n Template:     blaskan\n Version:      1.0.0\n Text Domain:  blaskan-child\n*\u002F\n","css","",[31,86,87,96,102,108,114,120,126,132,138,144],{"__ignoreMap":84},[88,89,92],"span",{"class":90,"line":91},"line",1,[88,93,95],{"class":94},"sJ8bj","\u002F*\n",[88,97,99],{"class":90,"line":98},2,[88,100,101],{"class":94}," Theme Name:   Blaskan Child\n",[88,103,105],{"class":90,"line":104},3,[88,106,107],{"class":94}," Theme URI:    https:\u002F\u002Fyoursite.com\n",[88,109,111],{"class":90,"line":110},4,[88,112,113],{"class":94}," Description:  A child theme for Blaskan\n",[88,115,117],{"class":90,"line":116},5,[88,118,119],{"class":94}," Author:       Your Name\n",[88,121,123],{"class":90,"line":122},6,[88,124,125],{"class":94}," Author URI:   https:\u002F\u002Fyoursite.com\n",[88,127,129],{"class":90,"line":128},7,[88,130,131],{"class":94}," Template:     blaskan\n",[88,133,135],{"class":90,"line":134},8,[88,136,137],{"class":94}," Version:      1.0.0\n",[88,139,141],{"class":90,"line":140},9,[88,142,143],{"class":94}," Text Domain:  blaskan-child\n",[88,145,147],{"class":90,"line":146},10,[88,148,149],{"class":94},"*\u002F\n",[10,151,152,153,155,156,158,159,162,163,166],{},"The ",[31,154,76],{}," value must match the folder name of the parent theme exactly (lowercase, as it appears in ",[31,157,53],{},"). If Blaskan is installed in a folder named ",[31,160,161],{},"blaskan",", then ",[31,164,165],{},"Template: blaskan"," is correct.",[10,168,169],{},"After the header comment, you can add any CSS you want to override or extend. This CSS loads after the parent theme's CSS, so your rules take precedence.",[17,171,173],{"id":172},"the-functionsphp-file","The functions.php File",[10,175,176,177,179,180,183],{},"The child theme's ",[31,178,39],{}," is responsible for properly loading the parent theme's stylesheet. Create ",[31,181,182],{},"blaskan-child\u002Ffunctions.php"," with:",[79,185,189],{"className":186,"code":187,"language":188,"meta":84,"style":84},"language-php shiki shiki-themes github-light github-dark","\u003C?php\nadd_action( 'wp_enqueue_scripts', 'blaskan_child_enqueue_styles' );\n\nfunction blaskan_child_enqueue_styles() {\n    wp_enqueue_style(\n        'blaskan-parent-style',\n        get_template_directory_uri() . '\u002Fstyle.css'\n    );\n}\n","php",[31,190,191,196,201,207,212,217,222,227,232],{"__ignoreMap":84},[88,192,193],{"class":90,"line":91},[88,194,195],{},"\u003C?php\n",[88,197,198],{"class":90,"line":98},[88,199,200],{},"add_action( 'wp_enqueue_scripts', 'blaskan_child_enqueue_styles' );\n",[88,202,203],{"class":90,"line":104},[88,204,206],{"emptyLinePlaceholder":205},true,"\n",[88,208,209],{"class":90,"line":110},[88,210,211],{},"function blaskan_child_enqueue_styles() {\n",[88,213,214],{"class":90,"line":116},[88,215,216],{},"    wp_enqueue_style(\n",[88,218,219],{"class":90,"line":122},[88,220,221],{},"        'blaskan-parent-style',\n",[88,223,224],{"class":90,"line":128},[88,225,226],{},"        get_template_directory_uri() . '\u002Fstyle.css'\n",[88,228,229],{"class":90,"line":134},[88,230,231],{},"    );\n",[88,233,234],{"class":90,"line":140},[88,235,236],{},"}\n",[10,238,239,242,243,246],{},[31,240,241],{},"get_template_directory_uri()"," always returns the parent theme URL regardless of which theme is active. This is important: do not use ",[31,244,245],{},"get_stylesheet_directory_uri()"," here, which would return the child theme URL and cause the parent styles to not load.",[10,248,249,250,252,253,256],{},"If you also want to load the child theme's ",[31,251,33],{}," (to apply the overrides you added there), add a second ",[31,254,255],{},"wp_enqueue_style"," call with the child theme's stylesheet URL and declare it as dependent on the parent style:",[79,258,260],{"className":186,"code":259,"language":188,"meta":84,"style":84},"wp_enqueue_style(\n    'blaskan-child-style',\n    get_stylesheet_directory_uri() . '\u002Fstyle.css',\n    array( 'blaskan-parent-style' ),\n    wp_get_theme()->get( 'Version' )\n);\n",[31,261,262,267,272,277,282,287],{"__ignoreMap":84},[88,263,264],{"class":90,"line":91},[88,265,266],{},"wp_enqueue_style(\n",[88,268,269],{"class":90,"line":98},[88,270,271],{},"    'blaskan-child-style',\n",[88,273,274],{"class":90,"line":104},[88,275,276],{},"    get_stylesheet_directory_uri() . '\u002Fstyle.css',\n",[88,278,279],{"class":90,"line":110},[88,280,281],{},"    array( 'blaskan-parent-style' ),\n",[88,283,284],{"class":90,"line":116},[88,285,286],{},"    wp_get_theme()->get( 'Version' )\n",[88,288,289],{"class":90,"line":122},[88,290,291],{},");\n",[10,293,152,294,297],{},[31,295,296],{},"array( 'blaskan-parent-style' )"," parameter tells WordPress to load the parent style before the child style, which ensures your overrides apply correctly.",[17,299,301],{"id":300},"activating-the-child-theme","Activating the Child Theme",[10,303,304,305,309,310,313],{},"Go to ",[306,307,308],"strong",{},"Appearance > Themes"," in the WordPress admin. The child theme appears as a separate theme. Click ",[306,311,312],{},"Activate",". Your site now runs on the child theme. Blaskan (the parent) remains installed and provides all templates, scripts, and styles that the child theme does not explicitly override.",[17,315,317],{"id":316},"overriding-templates","Overriding Templates",[10,319,320],{},"To change how a specific part of the site renders, copy the relevant template file from the Blaskan folder into the child theme folder, maintaining the same directory structure, and edit the copy.",[10,322,323,324,327,328,331],{},"For example, to modify the single post template: copy ",[31,325,326],{},"blaskan\u002Fsingle.php"," to ",[31,329,330],{},"blaskan-child\u002Fsingle.php",", then edit the child theme copy. WordPress's template hierarchy checks the child theme folder first, so your modified version is used instead of the parent's.",[10,333,334],{},"Templates you have not copied continue to be served from the parent theme. You only override what you need.",[17,336,338],{"id":337},"naming-and-organization-conventions","Naming and Organization Conventions",[25,340,341,344,350,357],{},[28,342,343],{},"Keep the child theme folder name lowercase with no spaces",[28,345,346,347,349],{},"Match the ",[31,348,76],{}," value to the exact folder name of the parent theme",[28,351,352,353,356],{},"Use the child theme's ",[31,354,355],{},"Text Domain"," consistently if you add any translatable strings",[28,358,359],{},"Document any non-obvious overrides in comments within the relevant file",[10,361,362,363,368,369,373,374,62],{},"For questions about what can be customized at the theme settings level (without needing a child theme), see the ",[364,365,367],"a",{"href":366},"\u002Fcustomization\u002F","customization overview"," and ",[364,370,372],{"href":371},"\u002Fcustomization\u002Fheader-logo-menu-behavior\u002F","header, logo, and menu behavior",". For support with a specific implementation, see the ",[364,375,377],{"href":376},"\u002Fsupport\u002F","support page",[379,380,381],"style",{},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sJ8bj, html code.shiki .sJ8bj{--shiki-default:#6A737D;--shiki-dark:#6A737D}",{"title":84,"searchDepth":98,"depth":104,"links":383},[384,385,386,387,388,389,390],{"id":19,"depth":98,"text":20},{"id":46,"depth":98,"text":47},{"id":65,"depth":98,"text":66},{"id":172,"depth":98,"text":173},{"id":300,"depth":98,"text":301},{"id":316,"depth":98,"text":317},{"id":337,"depth":98,"text":338},"2025-11-20","2024-05-01","How to create a Blaskan child theme to make safe, updatable customizations to the WordPress theme without editing core files.","md","Code editor showing a WordPress child theme style.css header and functions.php file","\u002Fimages\u002Fpages\u002Fchild-theme-basics-1600x900.jpg","default",{"heroLabel":399},"Documentation","Create a Blaskan child theme to make safe, updatable customizations without editing core theme files.","Child Theme Basics for Blaskan","\u002Fdocumentation\u002Fchild-theme-basics","article",{"title":5,"description":393},"documentation\u002Fchild-theme-basics","WZVfoYFkUYigWB-XkyWmEvUteiuPkIh4wfI15JDOL9E",1775942365266]