Creating a new Template

Skinning and designing Serendipity (CSS, HTML, Smarty)
Post Reply
trimstah
Posts: 4
Joined: Tue Jul 01, 2008 9:12 pm

Creating a new Template

Post by trimstah »

Looking at the style page here, http://www.s9y.org/44.html. It mentions the best way to design a new template is to copy a template subdirectory and create a new one.

I've done this and went to admin page to see if the new template showed up, but it doesn't. Am I missing a step here?
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Creating a new Template

Post by garvinhicking »

Hi!

Did you copy all files, and then change the info.txt to change the name of the template to your new, own one? Having a unique name is important to distinct it from theother...

HTH.,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
trimstah
Posts: 4
Joined: Tue Jul 01, 2008 9:12 pm

Post by trimstah »

Hi Garvin

I renamed the info.txt in the template folder like you said but the template still doesn't show up in the manage styles admin page.

The subdirectory I copied was "default" and renamed to "test".
judebert
Regular
Posts: 2478
Joined: Sat Oct 15, 2005 6:57 am
Location: Orlando, FL
Contact:

Post by judebert »

So, you should now have two identical directories:
/serendipity/templates/default/
/serendipity/templates/test/

The /serendipity/templates/test/info.txt should have the following contents:
Name: New Template Test
Author: Your Name
Date: 07/01/2008
Require Serendipity: 0.8

When you go to the admin screen and click Manage Styles, the new template should be visible. The templates are displayed alphabetically by directory name.

You can delete all the other files in the test/ directory, and only include the ones that you intend to modify; all others will be taken from default/.
Judebert
---
Website | Wishlist | PayPal
trimstah
Posts: 4
Joined: Tue Jul 01, 2008 9:12 pm

Post by trimstah »

Yup, those are the steps I did.

Is there a configuration I'm missing? Do I need to add the template to a list somewhere else?

I'm guessing the template list on the admin page isn't generated off the folders under /templates/

As a test I removed one of the default templates, while the asset files were missing(imgs, css, etc), the admin page still showed the template as there (title, author, date, button to set as template, etc).
trimstah
Posts: 4
Joined: Tue Jul 01, 2008 9:12 pm

Post by trimstah »

Fixed. Looks like I was pointing to the wrong serendipity install.
Post Reply