Showing posts with label How to create custom WordPress theme?. Show all posts
Showing posts with label How to create custom WordPress theme?. Show all posts

Wednesday, 4 May 2016

Creating default blog page (home.php) and front-page.php

Previous tutorial : http://1wmedia.blogspot.in/2016/04/creating-custom-sidebar-multiple.html

In this tutorial, We will see how to create default blog page which is home.php and front-page.php for custom front page.

1. If you are following my previous tutorials, you may be created themes folder and all other files. If not, please view the previous tutorials.

2. In the theme folder, duplicate the page.php and save as home.php . This home.php file is your default blog page. Don't misspell this. Then it won't work.

3. Now it will take your default home page into blog page. If home.php not available, your front page will be your index.php.

4. So we need to create another file for front-page. So duplicate index.php and save as front-page.php.

5. This will automatically take your front page.

6. If you change some settings in Settings -> Reading ,  in Dashboard , then your front page will not work.

7. So create two new pages from Pages and add it to menus.

8. Now go to Settings -> Reading again . Choose your front page and blog page. and save it.

9. Refer the following link for WordPress Hierarchy -> https://wphierarchy.com/

Refer this video :





Tuesday, 23 February 2016

How to create a Bootstrap WordPress Theme? - Step 1

Hi All,

Necessary files to create Custom WordPress theme:
  1. style.css
  2. index.php 
You should create these files at the following location

1. In your WordPress installed folder - may be cpanel or local host (click to see how to install WordPress).  Find the "wp-content" folder. Click and open the folder

2.  Inside the  "wp-content" folder, You will see another folder named "themes". Click and open the folder.

3. Inside the "themes" folder, Create a folder with different name. It may be your theme name or a custom name.

4. Inside the newly created folder, create style.css and index.php

Simple steps :

WordPress Folder -> wp-content -> themes -> create a directory or folder with a name. (For Example :"myfolder") -> create style.css and index.php and save it.

Now you have created necessary files for your custom theme.

You should add the following code into your style.css file:


/*
Theme Name: Themename
Theme URI: 1wmedia.com
Author: 1wmedia.com
Author URI: http://1wmedia.com
Description: These the come with sidebar and full width pages.

*/  
In the above code,

Instead of "Themename " use your own or custom theme name. Others - you can use your own URI and Description.

Now login your dashboard -> Appearance -> Themes -> Your theme will display. -> click and activate the theme.

See the picture below:




First step is over. We will see next steps in next post.


Video Tutorial :