How to Create Custom Templates for Single Post in WordPress

While creating a site, have you felt the need to change the way of presenting a particular post? Why always have the same monotonous look by using the same template throughout the website. In this article, we will be showing you different ways to create a template for a single post in WordPress.

Why do we Need Custom Templates for a Single Post?

  • Posts can influence your audience to a great extend, helping you in marketing your site.
  • Relatively important content can make unique presence on your site.
  • It helps you distinguish your content, like posting similar content with the same templates helps your audience while viewing your site’s content.

Now, let us see the process of creating templates for a single post.

Creating Custom Single Post Template using Beaver Builder

Beaver Builder is a page builder plugin that lets you create single post templates. Let us see how to create single post templates using this plugin.

Step 1: Install and Activate the Beaver Builder plugin. Check “How to Install Plugins” for further details.

Step 2: Go to settings and then “Beaver builder” followed by the “License” tab to enter your license key.

Step 3: Now, enable “Posts” in Post type section. Click on “Save Post Type”.

Step 4: Now, create a new post and click on the “Launch Beaver Builder” button in the edit screen.

Step 5: Next, you will go to the live preview of your website. Simply add a template and you will see a blank template on your screen. Go ahead and add rows and columns to your template.

Step 6: Fill in different modules, elements and make other changes you wish to see in your templates. Finally, save the template when you are satisfied with all the settings.

Step 7: Save the template with an appropriate template name and use it in future for other posts as well.

Creating Custom Single Post Templates using Theme Settings

There are various themes in WordPress that permit you to customize your post templates. There might be slight differences in the setting options for different themes. In this article, we will be using Astra Theme.

Simply go to the post you would like to add the template to and then go to settings.

Here you can make various changes like menu, title, headers and create a customised template for your post.

This method is very easy but applicable for only a few themes in WordPress.

Creating Custom Single Post Templates using Block Editor

The group block is a block in WordPress you can reuse in multiple posts once you save it. In group block you add multiple blocks together to create a layout for your post.

Step 1: Create a new post in WordPress and click on “Add New”. Add a “Group Block”.

Step 2: Next, add different blocks to create a layout for your post.

Step 3: After you are satisfied with your layout, go to the menu and select the “Add to reusable blocks” option.

Step 4: Name this block and save it. You can use this layout for any post in your site.

Step 5: Select the “Add New” button and click on the “Reusable” option to select the layout you created.

This method just changes the basic layout of your post.

<h1>Creating custom single post templates manually:

Step 1: Open any text editor on your system and copy the following code:

<?php
/*
 	* Template Name: Featured Article
 * Template Post Type: post, page, product
 	*/
  
 	get_header();  ?>

This is to add new template called “Featured Article”. Save this file as “wpb-single-post.php”.

Step 2: Upload this folder in your WordPress theme folder.

Step 3: Now go to an existing post or create a new post in your WordPress admin area. In “Post Attributes” you will see the “Featured Articles” option, select it.

Step 4: Copy the code of single.php file of your theme and paste it in the wpb-single-post.php file. (Copy everything after the get_header line)

Step 5: Save the changes made and upload the file again in WordPress.

This creates a template similar to your theme. You can make various changes in the custom single post. You can make changes in CSS, add or remove headers or sidebar and any other change you wish.

We hope this article helps you create beautiful Custom Templates for your WordPress website. In case of queries, please leave a comment and we will get back to you as soon as possible.

Also, if you want us to cover a specific topic you can leave a comment for that as well.

Recent Articles

Standard Display Drivers for Windows 10 FAQ

Drivers act like a translator between the device they control, and the other programs in your system. Google Translate is not support in your...

Pictures Tutorial How to Reset USB Ports on Windows 10 8 7?

If you did not find it, close the window and update a different driver. Authentic and functional files are kept in a compressed cache...

How to properly update device drivers on Windows 10

Windows Update, Device Manager, and Auto-Update Assistants from device manufacturers. In most cases, these methods will keep your device drivers installed and updated properly....

Injustice: Gods Among Us APK OBB Download Install 1Click Obb Installer for Injustice: Gods Among Us

The traitor will need to be found before they can kill everyone else. You can download this game for your phone or tablet from...

Ohjelmien poistaminen Windowsista

Jos Lutriksesta ei ohjeita löydy tai jokin ohjelma ei suostu käynnistymään, kannattaa ensimmäisenä vilkaista Winen tietokannasta, onko sitä lainkaan mahdollista saada toimimaan. Bugiraportteja,...

Related Stories

Leave A Reply

Please enter your comment!
Please enter your name here