
Over the last couple of months I’ve been learning to code, partly just for the sake of something to learn, but also partly for the sake of developing a child theme for my blog. In this post, I’ll talk a bit about how the child theme creation process is going, but to start off, what the heck is a child theme?
Every WordPress blog has a theme. Themes are layered on top of the WordPress core and influence the design of your site, both in terms of how it looks when other people are looking at it and how it looks to you in the editor. A child theme is layered on top of a parent theme to further influence how a site looks and behaves. The reason for creating a child theme rather than just tweaking the parent theme directly is that each time a new update of the parent theme is released, any modifications that an individual user had been made to the previous version of the parent theme are lost. Because a child theme sits on top of a parent theme, it keeps on doing its thing even if the parent underneath it has updated.
Another way of customizing WordPress sites is adding plugins (although most WordPress.com plans don’t let you do that). These add extra functionality. Since the child theme I’m building is just for me rather than being created for other people to be able to use, I’m actually focusing more on functionality than presentation, but it’s easier to do things all in one place in the child theme than to create a plugin as well.
My child theme
Today was the first time trying out the child theme on my actual site. Up until now, I’ve just been working on it using a test site that only runs on my computer. My child theme changes a few things behind the scenes, including incorporating some functionality that I’ll no longer need to use plugins for. It changes very little about the way my site looks, though, because I’m using the same code for that kind of thing as I had already been using as custom CSS (Cascading Style Sheets) code in my parent theme (which is Astra).
One thing I’ve added is making an author bio appear at the bottom of posts, but only on specific post categories and only on the site itself rather than in the RSS feed, which is what’s displayed in feed readers like the WordPress Reader. I’m not actually changing the content of the posts themselves, but tacking an extra bit of code on right when a post is being displayed. I felt rather pleased with myself when I got that working.
Speaking of the RSS feed, I have my Amazon author profile set up to display my blog feed, but there are certain categories of posts that I’d rather not have displayed there. To address this, I used my child theme to create a custom RSS feed in addition to the feed WP automatically creates for my site, and my custom feed filters out posts from specific categories.
I had things working with a feed reader I found that could display feeds created by a local site that wasn’t actually on the internet… or at least, it was working the last time I had tested it. Somehow, I managed to break it since then without realizing it. Anyway, when I uploaded the child theme to my live site, not only did the custom RSS feed not work, but it managed to break my regular feed as well. I’ve disabled the custom RSS feed until I can figure out how I managed to fuck it up, and I think I’ve unbroken the regular feed, but it’s a toss-up whether this post will appear in the WP Reader.
Work in progress: custom blocks
I’ve been using a plugin that was called Ultimate Add-Ons for Gutenberg that includes a number of different types of blocks above and beyond the standard block types available in WordPress (like a table of contents block I use on several of my site”s pages). The plugin-maker has recently totally overhauled the plugin and the overhauled version is a bit of a disaster, so I decided to try to use my child theme to create the block types I want to be able to use rather than having to use the plugin. I took a LinkedIn Learning course to learn how to create custom blocks, and now I’m in the process of trying to build a table of contents block.
If you think the block editor is a pain in the ass to use, blocks are even more of a pain in the ass to code. A lot of WordPress stuff is coded using the PHP language, but building Gutenberg blocks involves a different language (JavaScript), plus some other stuff on top of that (React and npm).
So far, I’ve got my basic custom block created and I can use use it in posts just like any other kind of block. Now I’m working on the hard part, which is getting it to generate a functioning table of contents on the fly using the headings in a post.
So that’s a bit of an update on what I’m working on. I know this is something the vast majority of people will have less-than-zero interest in doing for their own site, but I’m finding it kind of fun to tinker around with WordPress nuts and bolts.

The blogging toolbox series has tips to support you in your blogging journey. It includes these posts:
Wow! Great adventures in coding, Ashley Leia. I like your addition of the Author’s Bio on your main flagship page. Looks great! The layout seems different to me on your main page too. But then again, I usually read your posts through the WP reader/notifier you may have changed your front page layout ages ago.
Thanks! I changed the front page a few weeks ago after I learned a few new tricks using CSS.
Looks excellent!👍
Thank you!
I took a coding course once. I liked the “coding for kindergarteners” unit best. Wll done on learning such an amazing new skill. How neat to be able to have such control over your site.
I have to admit, when you’d previously referenced a child-theme, I thought it had something to do with kiddos.
Hmm, I’d hoped that would display the image right here, but I guess not
It displays for me in the WP reader
Yeah, it shows up in mine too. I think the issue was after I fixed the feed, the Reader hung onto the cached broken version until it recognized the regenerated version.
I notice the Reader does that when I edit blog posts too. It’s frustrating.
Yup.
So cool that you’re learning to code! I tried to get into it a while back and learnt HTML and CSS, but eventually decided it wasn’t something I wanted to pursue further. I totally respect the ability to code though, that skill is so nitpicky over every small detail it’s crazy.
I find HTML incredibly annoying to type. All of those closing tags like are so awkward for for the fingers.
I make table of contents manually using html anchors. Time consuming as hell.
A block which automatically geverates them would be really cool!
I used to do them manually but I kept making errors in my HTML anchors, only some of which I would actually notice. I need something automated to save me from myself.
Oh yeah, same here. It’s so incredibly frustrating because the preview function can have problems too so I would keep having to switch to draft, publish the blog post, switch to draft etc etc, to check the anchors. There’s a “pending review” option, but I never tried it, so I don’t know if that’s better than publishing a bunch of times.
I don’t think pending reivew would help in that situation.
I give you loads of props for learning to code! That shit aint easy thats for sure!
Thank you!
Wow, Ashley – impressive!
Thank you!
I seriously thought you meant a mental health for children version of your blog every single time you’ve mentioned the child theme. Now it all makes sense, and I feel pretty dumb. Hehe. Although a place for mental health info for children would maybe also be a worthy niche…
It would.
I tend to forget that other bloggers have zero reason to have any idea what I’m talking about when I use obscure technical terms. I should really remember to explain myself more…
This is the only time I’ve have ever been confused on your blog. You always take us by the hand, as you did in this one. I think you mentioned the child theme before in some of the weekly summaries. You can hardly expect a full explanation there!?
I think this was the first time I actually explained it, and I don’t think anyone else knew what I’d been talking about either. 😉
Hehe. Oops.
I love hearing about your endeavor. Please keep us updated on your progress.
Thanks! Will do!
Oh my gosh! You are such an achiever! I am inspired, but need to do everything in baby steps 🤦♀️ – Still working on that pinterest project LOL I am definitely bookmarking this for future reference.
❤️❤️
It’s nice to know how your child theme is coming along and to get a sneak peek when things well get messed up for no good reason 😅
My site had a major breakdown this summer when I was trying to move off-site changes online and got disconnected from my web host sometime during the transfer 😅 Fun times 😂🙈
Oh no!
Okay all the best with your project🔥
Thank you!