Page Templates help you standardise how multiple pages look/work
A Page Template is an essential component, any of our Marketplace Templates will come with at least one already but you can create them here:
SiteBuilder simply leverages the Page Templates functionality in Siteglide but builds it for you with useful options to save you time.
In the popup, choose:
A name e.g. "Main"
Default Page Template - optional
the Flowbite Theme (other SiteBuilder Themes will be available to download from Marketplace)
Optionally, add a Menu, but this is not neccesary for this tutorial
Themes automatically add any of the following to a Page Template:
CSS
JavaScript
Config Files
Standard Page Template HTML and Liquid
These will then be applied consistently to any Page the Page Template is attached to.
Once created, you can find your template in the SiteBuilder Page Templates tab and in the Siteglide Admin under SITE MANAGER > Templates
. These Page Templates are fully editable and you can attach them to Siteglide Pages as normal.
Once you've created a Page Template, you'll unlock the PageBuilder, Layouts and Settings tabs.
The Flowbite template starts with a default Tailwind CSS file which allows most layouts to work out of the box, but if you want to start changing things, you'll need to follow the rest of these setup steps!
When creating your Page Template, you can select a Tailwind build method of either:
CLI
Preview
Use the default from the SiteBuilder Settings tab
When editing your Page Template later, you can modify the template_build_method
parameter and set it to either 'cli'
, 'preview'
or empty string ''
.
You can learn more about which build method to use here, or continue to set up our recommended CLI method!
SiteBuilder Themes help you to find content for your site which uses a consistent CSS and JS framework.
A Theme becomes active when you create a Page Template in SiteBuilder using that Theme in the Page Templates tab.
Each Theme will have a different combination of features:
CSS or JavaScript Framework e.g. Bootstrap / Tailwind
The selection of Modules supported
The selection of Dynamic and Static Layouts available
We recommend using the Flowbite TailwindCSS Theme, SiteBuilder is setup to work best with Flowbite and you will find more layouts and features available for Flowbite than other Themes.
Take these into consideration and choose a Theme which is the best fit for your project.
More Themes are available on the Siteglide Marketplace. Any Themes which you decide not to use can be safely uninstalled from your Site, except for any that ship with the main SiteBuilder Module.
Marketplace Templates help you get started quickly without having to build a site from scratch. Templates will generally be based on a specific Theme (Flowbite or Bootstrap5 typically).
Why not test it out by creating a site from a template?
Build a Site using a SiteBuilder Template
From the Siteglide Portal on either the Dashboard page or the Sites page you should see a button to create a new site. It will open a modal to select either a Template or Custom Site.
This will take you to the Marketplace where you can select a category of templates. You can choose between all of our Flowbite layout templates or a couple of Bootstrap 5 options. It's recommended to use Flowbite, especially if you're familiar with Tailwind.
We recommend starting with the Landing Page or the Marketing Site Template. Choose the Marketing Site if you want to see more Siteglide functionality or the Landing Page if you'd rather just learn the basics first.
Finally, give your site a name and click 'Create Site'.
And that's it! You've successfully created a new site, you will need to wait for it to be ready to use. You will receive an email when it's done but can also find it under the Sites area:
Continue with our Quickstart guide?
The SiteBuilder Module must be installed to use SiteBuilder
Check if you have already installed the SiteBuilder Module on your site (click Install if not).
The version should be at least 4.11.2 (we'd recommend updating to the latest version).
The SiteBuilder Module comes with the Free Flowbite Theme automatically.
If the download does not show as Installed after some time, try refreshing the page and trying again - it is a large package of files.
You'll need to create a Page Template:
Working with Tailwind via our CLI
You must already have a Site with SiteBuilder installed and have our CLI installed
If you don't have the Siteglide CLI installed or need help with the CLI follow our Quickstart guide:
Using the Command Line Interface (CLI) to build a Tailwind CSS file allows you to:
Use the latest versions of TailwindCSS and its various 1st and 3rd party plugins.
Get the best performance front-end as Tailwind can scan your entire codebase to carry out "tree-shaking" to only include utility classes you actually need
Faster development performance as you can rebuild your CSS faster, and therefore build things faster
Each time you start working on a new project, you will need to follow these steps, however, the setup time is worth it as it will give you a much smoother experience going forward.
Older versions of SiteBuilder would have defaulted to use the JIT option as a default. Make sure it's set to CLI!
You will need to install Siteglide CLI- if you haven't or are not sure if you have, head here first:
Next you'll need to follow the steps to create a project folder for your new Site and setup Siteglide CLI for this new Site:
Once you've pulled the Codebase for the new Site down into your project folder, continue to the next step.
We'll be using npm (Node Package Manager) to install the software and settings we need to run Tailwind on your machine. This is the same tool you will have used to install the Siteglide-CLI.
We've built files in the Site Template which contain the instructions npm needs to set you up automatically.
Find the files in the folder:
And copy and paste these two files package.json
and package-lock.json
into the root project folder (next to- but not inside - marketplace_builder).
Next, move the tailwind.config.js
and tailwind.css
files from the copy_and_paste_my_files_into_the_src_folder
folder to the marketplace_builder/assets/modules/module_86/src folder
:
Using your integrated terminal from step 2, which is already open in your project directory, run the command:
You may be given some warnings and information by npm at this stage. For the sake of this tutorial most are safe to ignore for now and come back to later.
Split your terminal in two. We'll need one window to build our Tailwind CSS and a second one to sync our changes to the Site:\
Use this command to build your Tailwind's CSS (we'll look at this in more detail in a minute):
In the other terminal window, use this command to sync changes to the Site with Siteglide-CLI (replace <env> with your environment name from step 2):
Both commands will keep running indefinately and will watch your files for changes. Every time you change a Liquid file the Tailwind will re-compile the CSS if it needs to!
You can now start building your Site using Tailwind CSS!
Head to the next article to understand in more depth:
The Tailwind Config File
The Tailwind source CSS file
The Tailwind distributable CSS file