Book Image

Creating Concrete5 Themes

Book Image

Creating Concrete5 Themes

Overview of this book

Creating a concrete5 theme isn't complicated if there’s already a HTML document. There are only very few PHP functions you’ll have to add, but those are powerful and give you a lot of freedom. As you’ll learn to create mobile ready themes, you’ll start to see that there’s almost no limit in what you can do."Creating Concrete5 Themes" is a practical, hands-on guide that provides you with a number of examples that will teach you how to create powerful concrete5 themes, change the look of content block elements, and even make your site ready for mobile devices."Creating Concrete5 Themes" starts with a few words about the editing concept and architecture of concrete5 and then continues with the creation of a basic theme which gets extended with more and more elements until the theme is mobile ready.You will learn where to find the information necessary to get your own concrete5 site and then get a quick introduction to understand the idea of the in-site editing concept. We’ll then create a theme which is extended with features and more details as we progress. You’ll also see some examples to show you the process of overriding elements from the core without losing the ability to upgrade concrete5 in the future. Once we’ve customized every element in concrete5 to build a complete theme, we’ll have a look at responsive techniques to make your site ready for small screen devices such as mobile phones and tablets.  
Table of Contents (13 chapters)
Creating concrete5 Themes
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Index

Overriding the single page's HTML output


If you don't like the look of the login page, you can always add some lines to your CSS file to change it, but there's another way. We're going to override the whole single page template this time. It's not always clear as to why you should keep using CSS or override the template. It's just important to keep in mind that with this approach, we're going to copy quite a few lines of code. If something changes in a future version of concrete5, you might have to check your custom single page template as well.

Before we change anything, let's have a look at the following illustration. It shows the flow that the login single page goes through by default:

It's pretty much the same as shown in the first illustration a few pages earlier. Now, let's override it; but first, create another clone of your theme bootstrap7 called bootstrap8. Make sure you change the theme name in /config/ site_theme_paths.php as well.

In the new theme, create a new file called login...