How to edit custom pages in WordPress?

Credit: wiki

In wordpress, you can write a new page by "writing page", but this method is the same as writing an article, except that the page content is edited like an article, and the page layout is still the same as the template, and the page layout style cannot be customized. 


But we can define the content, style and layout of the page by creating a page template, and implement a custom page by setting the page to use the newly created page template. Specific steps are as follows,


Use a text editor to create a php file named abc under the template directory, enter the following code, and save the abc.php file in utf-8 format.

<?php 
/*
Template Name:ABC
?>
<h1>Welcome to eng.thebetterlives.com</h1>
<p>This is a custom page</p>
<?php
/*
Template Name:ABC 
*/
?>

This part of the code tells wordpress that this is a page template called abc.


Then log in to the WordPress background, click "Compose", "Compose Page" to open a new page, enter the title name, such as ABC, no need to enter content, find the "Page" or "Page Template" column in the lower right corner of the page, if you have already abc.php is correctly saved in the template directory, then you can see the ABC option in the drop-down menu.


Support my writings and so that I can continue bring such awesome content for you. You know it take a lot of hard work to write an article. Just a small donation of $10 or more can help me to accomplish to reach a goal i.e. to buy a Car.

https://www.paypal.me/SachinDabodiya

Post a Comment

I will catch you soon

Previous Post Next Post