Are you prepared to begin creating your own WordPress themes? You are at the right spot!
Discovering how to build custom WordPress themes gives you access to a completely new universe. It enables you to create unique designs for yourself, your customers, and even the open-source community. We’ll take you from scratch to having a fully working theme that can be added to the WordPress.org theme directory in this tutorial. You’ll need a fundamental grasp of HTML, CSS, PHP, and WordPress functionality to follow along.
Step #1: To keep your theme files, create a directory
We need to determine where the files that constitute a WordPress theme are located in a WordPress installation if we’re going to construct themes. This is quite simple.
Create a Folder with the name of Your Theme.
Create Standard Files
- index.php
- style.css
- header.php
- footer.php
- functions.php
- archive.php
- single.php
- page.php
- 404.php
- screenshot.png
Here is what our root directory looks like in VS Code (IDE).
Note: screenshot.png I created for theme thumbnail, if you want just below click and download that thumbnail. Download Here
Add Style Comment
In reality, WordPress reads the comments you include in the style.css file.
That comment actually required for every wordpress theme, because it has every single piece of information about our theme. Like it assigns a theme name, the author, the author url, and the version of our theme.
Just copy below comment and paste it into style.css file
/* Theme Name: Medicure Theme URI: https://codestuffing.com/theme-development/ Author: Codestuffing Author URI: https://codestuffing.com/ Description: The biggest WordPress Theme ever License: Themeforest Split Licence License URI: https://themeforest.net/licenses/standard Text Domain: codestuffing Version: 1.0 */
Appearance -> Themes
Now it’s time to visit wordpress dashboard and navigate to Appearance -> Themes, we will see the new medicure theme there and which we have created it.
Now “Activate” your custom wordpress medicure theme.
#BeingCodeStuffer