diff template for diff category
-
- Regular
- Posts: 340
- Joined: Sun Jun 12, 2005 5:28 am
diff template for diff category
Is it possible to change the template based on which category the viewer is on.
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: diff template for diff category
Yes, by writing a plugin.
Using the "frontend_configure" hook you can do:
Regards,
Garvin
Using the "frontend_configure" hook you can do:
Code: Select all
if ($serendipity['GET']['category'] == 2) {
$serendipity['template'] = 'template1';
} elseif ($serendipity['GET']['category'] == 3) {
$serendipity['template'] = 'template2';
}
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/
# 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/