Skip to content

Installation

ookhrimenko edited this page Jan 17, 2018 · 7 revisions

This boilerplate theme is good for the custom development of medium and big sites with a custom design. We do not recommend using it to develop themes that will be sold on resources like themeforest.

Requirements

Installation from scratch

If you develop a new project from scratch, we recommend using WordPress Starter to setup WordPress, plugins, and quickly generate a new theme.

After creating a composer project, you will need to run a custom composer command:

composer wp:theme

Without any arguments it will print these usage instructions:

New theme generator based on Justcoded Theme Boilerplate (https://github.com/justcoded/wordpress-theme-boilerplate)

Usage:
     wp:theme -- <folder-name> [-t="My Theme"] [-ns="ClientName"] [-dir="wp-content/themes"] [-s, silent install]

Options:
     -t          Theme name displayed in WordPress admin panel
     -ns         Namespace to be used for theme classes
     -dir        Theme base directory. Default to 'wp-content/themes'
     -s          Silent install, set up a theme without confirmation message

For example, you want to create a theme for "The Times" newspaper so that the command will look like this:

composer wp:theme -- the-times -t "The Times" -ns "TheTimes"

After the successful message, you can start using/developing the theme.

If you don't have WordPress Theme Framework and Titan Framework plugin installed (or they are disabled) you will see a notice on a WordPress Dashboard and PHP Fatal error on the frontend.

Adding a boilerplate without WordPress Starter/composer

To add this boilerplate to your project, you will need to download the following packages manually:

Theme Boilerplate master branch or latest tag. – Theme Framework master branch or latest ta. – The latest version of Titan Framework.

Then unzip the boilerplate into wp-content/themes/boilerplate folder.

Also, unzip framework plugins into wp-content/plugins/ folder and activate them via WordPress Dashboard.

If you don't have WordPress Theme Framework and Titan Framework plugin installed (or they are disabled) you will see a notice in WordPress Dashboard and PHP Fatal error in the frontend.


Next: Theme Structure