In WordPress terminology:
A WordPress Theme is a collection of php, css & js files that work together to produce a webpage with an underlying unifying design for a weblog. These files are called template files. A Theme modifies the way the site is displayed, without modifying the underlying software.
A Wordpress Template defines part of a web page generated by a WordPress theme.
Example: header.php, index.php, sidebar.php & footer.php is a default template used in most WordPress themes. It defines the header, index, sidebar & footer area of web pages generated by WordPress.
The header & footer file will typically be loaded on every page of your WordPress site, allowing changes to be made to a single file, that will apply across the entire website.
The minimum number of files required for WordPress Themes only need an index.php template and a style.css file.
Lets create the directories and files that will make up our theme. Most WordPress themes have some default templates with code to generate HTML output for particular sections of a website.
Create a folder in wp-content/themes/ for your theme. for this tutorial Ill be using evtech, but it can be whatever you want and create the following blank files and folders in that new folder.
Main index.php. To display the main page of a website.
Header header.php. Displays the header section.
Sidebar sidebar.php. Generates HTML output for the sidebar section.
Footer footer.php. Displays the footer section.
Theme Functions functions.php. Contains code and functions to be used in a theme.
Single Post single.php. Displays the single post page.
Comments comments.php. Displays comments and comment form.
0 Comment(s)