Loading...
Skip to main content
Home Page
About
Marketplace
Sample page
Wishlist at dev site
Sitemap (Categories)
Tiki Customization
Creating a theme
Converting a Bootstrap theme
Contributing, sharing or selling
Customizing icons
Tips
Template Tricks
CSS Tricks
Feature Examples
Articles
Blogs
Calendar
Forums
FAQs
Trackers
Files
Links Directory
Wiki Pages
Find
History: Template Overview
View published page
Collapse Into Edit Sessions
Source of version: 7
«
»
''(from [http://doc.tikiwiki.org/tiki-index.php?page=Styles+and+Themes|Style and Themes] - to be updated)'' !! How to modify .tpl files __About Smarty__ The .tpl (template) files are written using the Smarty template language, which has its own syntax, etc. Smarty is mainly used for defining environment variables and the logic that follows (like who to show what when how). See [http://smarty.php.net/|smarty.php.net]. You can modify just the html in .tpl files though, and comment out some of the logic for features you never use. Be careful to keep backups though because a smarty error in a main template is a good way to crash your site. !!The Template Tree Tiki's templates are called in a specific order within the code, so it's good to know what is a parent of what, particularly for the main few used for the basic layout of the site. !!! Templates (most frequently modified) * ''tiki.tpl'': the main template defining the layout, which calls: ** ''header.tpl'': the HTML head section (avoid modifying, if possible) ** ''tiki-top_bar.tpl'': site Look & Feel options and/or menu ** ''tiki-site_header.tpl'': site Look & Feel options ** ''tiki-bot_bar.tpl'': bottom banner links/credits bar (Whether ''tiki-top_bar.tpl'' or ''tiki-site_header.tpl'' or both needs to be modified depends on what theme files are used as a starting point for a custom theme. ((Themes_for_TW2|New themes)) tend to use ''tiki-site_header.tpl'' for more Look & Feel components, and reserve ''tiki-top_bar.tpl'' for the menu (usually PHP Layers) and sometimes the search form.) (As of TikiWiki 2, there is no need to edit the error.tpl file (which formerly was identical to tiki.tpl except for having error-specific main content). Template files with names like ''tiki-print.tpl'' usually don't need to be changed. The layout of the whole Tiki page can be changed by modifying just one file or a few files. __Theme-Specific Templates__ To modify the layout of Tiki in your theme, edit theme-specific copies of default Tiki template files. While CSS editing is used to specify the details of page appearance, it is necessary to edit template files to make major rearrangements of items on the page. One example is to change the normal three-column layout to two or one columns, or to add a module to the top bar. !!Wiki Templates (More Advanced) * tiki-showpage.tpl - main wiki template, upper controls * tiki-page_bar.tpl - lower controls Unless there is a special need to emulate an existing theme, generally speaking, the best course is probably to base new theme templates on the default Tiki templates, that is, on templates/tiki.tpl, templates/tiki-top_bar.tpl, and so on. However, TikiWiki release 2 is in a transition period and the bundled themes include older ones that use an old-school table-based layout method, and new themes that use the *litecss table-free layout method. Choose as a model (and use the files of) whichever is closest to the target design (also see ((Themes_for_TW2)) ). !!! Overriding templates The template files for each theme are stored in a directory with the same name as the theme (less the ".css" file type indicator) in the ''templates/styles'' directory -- for example, ''templates/styles/screensite''. A theme's files will override any default template file. You just need to put a modified template file in the directory ''templates/styles/custom_theme_name''. For example, if we want to modify the forum listing in our ''screensite'' theme, we'd just place a copy of the file ''templates/tiki-forums.tpl'' in ''templates/styles/screensite/'' and then edit the new theme-specific copy of the ''tiki-forums.tpl'' file. Tiki will substitute whatever is in your custom theme directory for the .tpl files in the default directory. This technique works on files in the subdirectories, too. That is, to change the application menu in your theme, just copy the file ''mod-application_menu.tpl'' from ''templates/modules/'' to ''templates/styles/custom_theme_name/modules/''. It's recommended that as few template files be customized as possible, and the customizations kept as minimal as possible, in order to keep the maintenance and updating of the files easier. The more extensive the customization, the harder to keep in synch with the functionality of Tiki as it advances.
History
Enable pagination
rows per page
HTML diff
Side-by-side diff
Side-by-side diff by characters
Inline diff
Inline diff by characters
Full side-by-side diff
Full side-by-side diff by characters
Full inline diff
Full inline diff by characters
Unified diff
Side-by-side view
HTML diff
Side-by-side diff
Advanced
Information
Version
Mon 15 of Feb, 2016 12:51 GMT-0000
Jean-Marc Libs
17
Mon 15 of Feb, 2016 12:47 GMT-0000
Jean-Marc Libs
16
Wed 19 of Mar, 2014 01:27 GMT-0000
Marc Laporte
15
Sat 27 of Jul, 2013 07:08 GMT-0000
haggis73
changed url and comment to smarty.
14
Wed 30 of Jun, 2010 07:33 GMT-0000
Gary Cunningham-Lee
Some updating.
13
Wed 30 of Jun, 2010 06:45 GMT-0000
Gary Cunningham-Lee
Changed bold line to heading.
12
Wed 30 of Jun, 2010 06:44 GMT-0000
Gary Cunningham-Lee
typo
11
Wed 30 of Jun, 2010 06:43 GMT-0000
Gary Cunningham-Lee
Some updating.
10
Tue 27 of Jan, 2009 12:37 GMT-0000
Gary Cunningham-Lee
Updating
9
Tue 27 of Jan, 2009 12:34 GMT-0000
Gary Cunningham-Lee
Some updating.
8
Wed 08 of Oct, 2008 05:18 GMT-0000
Gary Cunningham-Lee
Some updating.
7
Mon 09 of Jun, 2008 15:12 GMT-0000
Oswaldo1965
6
Mon 21 of Apr, 2008 20:24 GMT-0000
mlpvolt
5
Fri 28 of Dec, 2007 20:30 GMT-0000
mlpvolt
4
Mon 20 of Feb, 2006 02:32 GMT-0000
Gary Cunningham-Lee
Minor edits.
3
Fri 17 of Feb, 2006 06:56 GMT-0000
System Administrator
Content added from doc.tw.o
2
Fri 17 of Feb, 2006 02:41 GMT-0000
system
created from structure
1
Select action to perform with checked...
Remove
OK
Layout
Stay on this page
Default
Single Container
Classic Bootstrap
Classic Tiki (3 containers - header, middle, footer)
Tikipedia
Latest Changes
Included themes
Bootstrap component sets
Materia
Ohia
Themes
Making or Updating a Theme for Tiki 27
Updating a Theme for Tiki 26
Tiki_org_family_customizations_CSS
BookStacked
Make an SCSS-Compiled Tiki Theme
...more
Subscribe to Tiki Newsletters!
Delivered fresh to your email inbox!
Don't miss major announcements and other big news!
Site Config
Site upgraded to branch 27x
Wed 24 of Apr, 2024 11:12 GMT-0000
Site upgraded to branch 26x
Wed 21 of Jun, 2023 09:45 GMT-0000
Site upgraded to branch 25x
Sat 12 of Nov, 2022 17:00 GMT-0000
Site upgraded to Tiki 23.x
Sat 24 of Jul, 2021 00:30 GMT-0000
Site upgraded to Tiki 20
Wed 29 of May, 2019 07:57 GMT-0000
We are now on Tiki 19.x
Fri 05 of Oct, 2018 10:02 GMT-0000
Shoutbox module removed
Thu 28 of Jun, 2018 07:01 GMT-0000
We are now on Tiki 18.x
Wed 02 of May, 2018 08:46 GMT-0000
Upgraded to Tiki 17.0
Wed 02 of Aug, 2017 08:19 GMT-0000