WordPress has great flexibility regarding theme and custom page, In wordpress you can define each page with different themes. In this post I will tell you how you can create custom page using custom page template. When you want create new landing page for new page/post then in wordpress you define new theme template file for this landing page/post. A custom page/post is helpful if you want to create page that looks different than rest of your blog under WordPress CMS. You can also use as HOME page of wordpress.In this template files you can define header and footer with new css files or existing css files.
Below steps are used to create custom page with custom theme templates:
Steps to create custom theme templates:
Step 1: We will create new blank files mvc.php and write below code at the very top of file.
<?php /* Template Name: mvc */ ?>
Above code tells the wordpress template name is MVC. It will show you as template name in wordpress when you will create custom page, you can change template name according your requirement. In This page you can define all CSS and design related work with PHP functionality.
Step 2: When You have completed your design and functionality then save it under your theme directory:
Steps to create Custom Page:
Step 1: Login in your wordpress admin dashboard using your credentials.
Step 2: Click add a new page under page menu.
Step 3: Now you can write the name of your custom page and leave the content area blank..
Step 4: Look on the right hand side, you will see a box called Attributes below the publish button. Select the template ‘MVC’ using the drag down button.
Step 5: publish the page.
Now you go to wordpress front end , here you will MVC link in main menu, Once you have clicked MVC you can see your theme design as you have defined earlier.