This is an old revision of the document!
If you are building a site from scratch, converting an existing site to GetSimple or you have a web page you want to use as a template you need to create a GetSimple Theme. There is a Step-by-Step Tutorial for converting a static html page into a simple theme. There is only one truly required theme file, and that's template.php
. You then place that file within it's own unique folder name, and install it on your server.
template.php
defines the html of the default page layout for most pages within your site, but you can make other page templates and set particular pages to use an alternative template by choosing it within the Page Options → Template setting:
Dynamic content is inserted into your page template by using template tags similar to WordPress (if you are familiar with that). All template pages are written in PHP.
the default page template template.php
goes inside a folder named specifically for your theme, and placed within the theme folder of your GetSimple installation such as: /path/to/getsimple/theme/my_theme/template.php
You can rename a theme by renaming the folder that contains it.
Other files found in a template folder are:
Normally an external stylesheet referenced in the html of the page template file.
Alternative templates for pages such as homepage.php
or contact.php
. They will be available for selection in Page Options.
A file named editor.css
in the theme folder will enable the CKeditor to display page content more accurately.
Any images used in the theme, along with favicons and backgrounds
These are some tips to help development of themes for GetSimple
/path/to/getsimple/gsconfig.php
file. Includes CKEditor, file upload, security, language and sitemap settings./path/to/getsimple/gsconfig.php
to enable full PHP errors to help debug./path/to/getsimple/data/other/logs/errorlog.txt
- It is automatically generated by the system regardless of the GSDEBUG setting./path/to/getsimple/theme/your-theme/functions.php
into your theme to add custom functions that can be used within your theme./path/to/getsimple/theme/your-theme/images/screenshot.png
to enable the theme image that shows when it s activated in the administrator panel. /images/
AND named screenshot.png
<?php if(!defined('IN_GS')){ die('you cannot load this page directly.'); } ?>
Back to the GetSimple Wiki Contents Page