PDA

View Full Version : Templating Quick Start



AniYishay
03-24-2009, 03:46 AM
How does the admin area get themed?
The admin theme reflects the main site theme.
This simply means that main.css is applied to both the front-end and back-end. The admin area can be changed separately based on anything you add to admin.css.

You are basically over-riding the main.css settings with anything you apply in admin.css.
It's quite simple because the front and back ends share the same ID's, Classes, and Element names.
(Excluding the Admin hover:Menu which is only used for admin.css)

This saves you time from having to customize two full CSS files. There is no need to create it from scratch :-)


My Template is Acting Funny!
If you are redesigning your template or installing a new one,
make sure to clear out everything from ~/templates_c,
which is your template cache.


Whats the Relative URL for files?
You can call anything from the TPL files by using template/~anything_here~, for example:

<link rel="stylesheet" type="text/css" media="screen" href="templates/css/main.css" />
<img src="templates/images/icon.png" alt="Icon" />

AniYishay
03-29-2009, 06:32 AM
I will update this once 1.0.1 is released, the templating has changed a little bit and Theme-ing will be available so templating with be twice as clean as before.

You will still be able to use your old layout but you will need to update your TPL files, from then on the your custom edited TPL files won't need to be changed because we have 'hooks' -- which Ill explain later!