forum.coppermine-gallery.net

No Support => Modifications/Add-Ons/Hacks => Mods: Visuals => Topic started by: davetd02 on January 16, 2004, 09:40:21 am

Title: Different themes for different albums?
Post by: davetd02 on January 16, 2004, 09:40:21 am
Is it possible (without diving too deep into PHP) to easily set a different theme for different albums?  I would like "Album X" to display in Theme X and "Album Y" to display in Theme Y.

Thanks a lot!

Dave
Title: Different themes for different albums?
Post by: Joachim Müller on January 16, 2004, 09:52:46 am
without hacking the code: no!

GauGau
Title: Where in the code would it need hacking?
Post by: davetd02 on January 16, 2004, 12:03:43 pm
THanks for the fast response.

If I were going to go ahead and hack the code, what general section would I need to hack?  I'm sure people have had this issue before.  I don't need a full tutorial (I'm sure it's a pretty simple if-then), but I don't know where to look to find where the theme is set.

Thanks!
Title: Different themes for different albums?
Post by: Joachim Müller on January 16, 2004, 05:18:12 pm
files that are involved in displaying album content are thumbnail.php and displayimage.php, but I'd go for include/init.inc.php, since it's the place where the request vars are handled.
You can use the var that is handed over by the url ($album). A simple statement like
Code: [Select]
if ($_GET["album"] == '1' ) { $theme='whatever';}should do the trick...

GauGau
Title: Perfect
Post by: davetd02 on January 16, 2004, 11:25:16 pm
That's exactly what I was looking for.

Thanks a lot!  You rock!
Title: Different themes for different albums?
Post by: sintax on February 02, 2004, 08:27:55 pm
Where would I put that in the init.inc.php file?

I want to use a different theme (located in the directory "pocky") on any images in Category 4.

Code: [Select]
if ($_GET["cat"] == '4' ) { $theme='pocky';}

Is how I think it would go... but where I do I insert that into the init.inc.php file?
Title: Different themes for different albums?
Post by: Nibbler on February 02, 2004, 08:46:55 pm
Put it in the gap at line 227, and you need to use $CONFIG['theme'] in place of $theme.
Title: Different themes for different albums?
Post by: Casper on February 02, 2004, 09:32:33 pm
If you use the code you have;
Code: [Select]
if ($_GET["cat"] == '4' ) { $theme='pocky';}

This will work, but only on the category page, and pics in the meta albums on the page, but not on the actual album pages within the cat.

I got it to work this far by changing this;
Code: [Select]
if (!file_exists("themes/{$CONFIG['theme']}/theme.php")) $CONFIG['theme'] = 'default';
        require "themes/{$CONFIG['theme']}/theme.php";
        $THEME_DIR = "themes/{$CONFIG['theme']}/";


to this;
Code: [Select]
if ($_GET["cat"] == '15' ) { $theme='water drop';
        require "themes/water_drop/theme.php";
        $THEME_DIR = "themes/water_drop/";
} else {

        if (!file_exists("themes/{$CONFIG['theme']}/theme.php")) $CONFIG['theme'] = 'default';
        require "themes/{$CONFIG['theme']}/theme.php";
        $THEME_DIR = "themes/{$CONFIG['theme']}/";
}



I think you also need to add the album id's to the 'if' query.
Title: Different themes for different albums?
Post by: sintax on February 02, 2004, 10:31:15 pm
I changed those three lines of my code to this:

Code: [Select]

if ($_GET["cat"] == '15' ) { $theme='pocky';
   require "themes/pocky/theme.php";
   $THEME_DIR = "themes/pocky/";
} else {

   if (!file_exists("themes/{$CONFIG['theme']}/theme.php")) $CONFIG['theme'] = 'default';
   require "themes/{$CONFIG['theme']}/theme.php";
   $THEME_DIR = "themes/{$CONFIG['theme']}/";
}


But am now getting the following error:

Code: [Select]

Parse error: parse error in /home/dizand2/public_html/gallery/include/init.inc.php on line 228

Fatal error: Call to undefined function: breadcrumb() in /home/dizand2/public_html/gallery/index.php on line 118


Any ideas?
Title: Different themes for different albums?
Post by: sintax on February 02, 2004, 10:35:43 pm
Just in case it will help anyone help me I figured I would post my code thus far:

Code: [Select]
<?php
// ------------------------------------------------------------------------- //
// Coppermine Photo Gallery 1.2.1                                            //
// ------------------------------------------------------------------------- //
// Copyright (C) 2002,2003 Gregory DEMAR                                     //
// http://www.chezgreg.net/coppermine/                                       //
// ------------------------------------------------------------------------- //
// Updated by the Coppermine Dev Team                                        //
// (http://coppermine.sf.net/team/)                                          //
// see /docs/credits.html for details                                        //
// ------------------------------------------------------------------------- //
// This program is free software; you can redistribute it and/or modify      //
// it under the terms of the GNU General Public License as published by      //
// the Free Software Foundation; either version 2 of the License, or         //
// (at your option) any later version.                                       //
// ------------------------------------------------------------------------- //
define('COPPERMINE_VERSION''1.2.1');
// User database integration
// Uncomment the applicable line if you want to use it
// define('UDB_INTEGRATION', 'phpbb');
// define('UDB_INTEGRATION', 'invisionboard');
// define('UDB_INTEGRATION', 'vbulletin');
// define('UDB_INTEGRATION', 'yabbse');
if (!defined('IN_COPPERMINE')) die('Not in Coppermine...');
// Start output buffering
ob_start();
// Report all errors except E_NOTICE
// This is the default value set in php.ini
// error_reporting (E_ALL ^ E_NOTICE);
error_reporting(E_ALL);

set_magic_quotes_runtime(0);
// used for timing purpose
$query_stats = array();
$queries = array();
function 
getmicrotime()
{
    list(
$usec$sec) = explode(" "microtime());
    return ((float)
$usec + (float)$sec);
}
$time_start getmicrotime();
// Do some cleanup in GET, POST and cookie data and un-register global vars
$HTML_SUBST = array('"' => '&quot;''<' => '&lt;''>' => '&gt;');
if (
get_magic_quotes_gpc()) {
    if (
is_array($HTTP_POST_VARS)) {
        foreach (
$HTTP_POST_VARS as $key => $value) {
            if (!
is_array($value))
                
$HTTP_POST_VARS[$key] = strtr(stripslashes($value), $HTML_SUBST);
            if (isset($
$key)) unset($$key);
        }
    }

    if (
is_array($HTTP_GET_VARS)) {
        foreach (
$HTTP_GET_VARS as $key => $value) {
            
$HTTP_GET_VARS[$key] = strtr(stripslashes($value), $HTML_SUBST);
            if (isset($
$key)) unset($$key);
        }
    }

    if (
is_array($HTTP_COOKIE_VARS)) {
        foreach (
$HTTP_COOKIE_VARS as $key => $value) {
            if (!
is_array($value))
                
$HTTP_COOKIE_VARS[$key] = stripslashes($value);
            if (isset($
$key)) unset($$key);
        }
    }
} else {
    if (
is_array($HTTP_POST_VARS)) {
        foreach (
$HTTP_POST_VARS as $key => $value) {
            if (!
is_array($value))
                
$HTTP_POST_VARS[$key] = strtr($value$HTML_SUBST);
            if (isset($
$key)) unset($$key);
        }
    }

    if (
is_array($HTTP_GET_VARS)) {
        foreach (
$HTTP_GET_VARS as $key => $value) {
            
$HTTP_GET_VARS[$key] = strtr($value$HTML_SUBST);
            if (isset($
$key)) unset($$key);
        }
    }

    if (
is_array($HTTP_COOKIE_VARS)) {
        foreach (
$HTTP_COOKIE_VARS as $key => $value) {
            if (isset($
$key)) unset($$key);
        }
    }
}
// Initialise the $CONFIG array and some other variables
$CONFIG = array();
$PHP_SELF = isset($HTTP_SERVER_VARS['REDIRECT_URL']) ? $HTTP_SERVER_VARS['REDIRECT_URL'] : $HTTP_SERVER_VARS['SCRIPT_NAME'];
$REFERER urlencode($PHP_SELF . (isset($HTTP_SERVER_VARS['QUERY_STRING']) && $HTTP_SERVER_VARS['QUERY_STRING'] ? '?' $HTTP_SERVER_VARS['QUERY_STRING'] : ''));
$ALBUM_SET '';
$FORBIDDEN_SET '';
$CURRENT_CAT_NAME '';
$CAT_LIST '';
// Record User's IP address
$raw_ip stripslashes($HTTP_SERVER_VARS['REMOTE_ADDR']);

if (isset(
$HTTP_SERVER_VARS['HTTP_CLIENT_IP'])) {
    
$hdr_ip stripslashes($HTTP_SERVER_VARS['HTTP_CLIENT_IP']);
} else {
    if (isset(
$HTTP_SERVER_VARS['HTTP_X_FORWARDED_FOR'])) {
        
$hdr_ip stripslashes($HTTP_SERVER_VARS['HTTP_X_FORWARDED_FOR']);
    } else {
        
$hdr_ip $raw_ip;
    }
}
// Define some constants
define('USER_GAL_CAT'1);
define('FIRST_USER_CAT'10000);
define('RANDPOS_MAX_PIC'200);
define('TEMPLATE_FILE''template.html');
// Constants used by the cpg_die function
define('INFORMATION'1);
define('ERROR'2);
define('CRITICAL_ERROR'3);

$IMG_TYPES = array(=> 'GIF',
    
=> 'JPG',
    
=> 'PNG',
    
=> 'SWF',
    
=> 'PSD',
    
=> 'BMP',
    
=> 'TIFF',
    
=> 'TIFF',
    
=> 'JPC',
    
10 => 'JP2',
    
11 => 'JPX',
    
12 => 'JB2',
    
13 => 'SWC',
    
14 => 'IFF'
    
);
// Include config and functions files
require 'include/config.inc.php';
require 
'include/functions.inc.php';

$CONFIG['TABLE_PICTURES'] = $CONFIG['TABLE_PREFIX'] . "pictures";
$CONFIG['TABLE_ALBUMS'] = $CONFIG['TABLE_PREFIX'] . "albums";
$CONFIG['TABLE_COMMENTS'] = $CONFIG['TABLE_PREFIX'] . "comments";
$CONFIG['TABLE_CATEGORIES'] = $CONFIG['TABLE_PREFIX'] . "categories";
$CONFIG['TABLE_CONFIG'] = $CONFIG['TABLE_PREFIX'] . "config";
$CONFIG['TABLE_USERGROUPS'] = $CONFIG['TABLE_PREFIX'] . "usergroups";
$CONFIG['TABLE_VOTES'] = $CONFIG['TABLE_PREFIX'] . "votes";
$CONFIG['TABLE_USERS'] = $CONFIG['TABLE_PREFIX'] . "users";
$CONFIG['TABLE_BANNED'] = $CONFIG['TABLE_PREFIX'] . "banned";
// User DB system
if (defined('UDB_INTEGRATION')) require 'bridge/' UDB_INTEGRATION '.inc.php';
// Connect to database
cpg_db_connect() || die("<b>Coppermine critical error</b>:<br />Unable to connect to database !<br /><br />MySQL said: <b>" mysql_error() . "</b>");
// Retrieve DB stored configuration
$results db_query("SELECT * FROM {$CONFIG['TABLE_CONFIG']}");
while (
$row mysql_fetch_array($results)) {
    
$CONFIG[$row['name']] = $row['value'];
// while
mysql_free_result($results);
// Set error logging level
if ($CONFIG['debug_mode']) {
    
error_reporting (E_ALL);
} else {
    
error_reporting (E_ALL E_NOTICE);
}
// Parse cookie stored user profile
user_get_profile();
// Authenticate
if (defined('UDB_INTEGRATION')) {
    
udb_authenticate();
} else {
    if (!isset(
$HTTP_COOKIE_VARS[$CONFIG['cookie_name'] . '_uid']) || !isset($HTTP_COOKIE_VARS[$CONFIG['cookie_name'] . '_pass'])) {
        
$cookie_uid 0;
        
$cookie_pass '*';
    } else {
        
$cookie_uid = (int)$HTTP_COOKIE_VARS[$CONFIG['cookie_name'] . '_uid'];
        
$cookie_pass substr(addslashes($HTTP_COOKIE_VARS[$CONFIG['cookie_name'] . '_pass']), 032);
    }

    
$sql "SELECT * " "FROM {$CONFIG['TABLE_USERS']}{$CONFIG['TABLE_USERGROUPS']} " "WHERE user_group = group_id " "AND user_id='$cookie_uid'" "AND user_active = 'YES' " "AND user_password != '' " "AND BINARY MD5(user_password) = '$cookie_pass'";
    
$results db_query($sql);

    if (
mysql_num_rows($results)) {
        
$USER_DATA mysql_fetch_array($results);
        unset(
$USER_DATA['user_password']);

        
define('USER_ID', (int)$USER_DATA['user_id']);
        
define('USER_NAME'$USER_DATA['user_name']);
        
define('USER_GROUP'$USER_DATA['group_name']);
        
define('USER_GROUP_SET''(' $USER_DATA['group_id'] . ($USER_DATA['user_lang'] != '' ',' $USER_DATA['user_lang'] : '') . ')');
        
define('USER_IS_ADMIN', (int)$USER_DATA['has_admin_access']);
        
define('USER_CAN_SEND_ECARDS', (int)$USER_DATA['can_send_ecards']);
        
define('USER_CAN_RATE_PICTURES', (int)$USER_DATA['can_rate_pictures']);
        
define('USER_CAN_POST_COMMENTS', (int)$USER_DATA['can_post_comments']);
        
define('USER_CAN_UPLOAD_PICTURES', (int)$USER_DATA['can_upload_pictures']);
        
define('USER_CAN_CREATE_ALBUMS', (int)$USER_DATA['can_create_albums']);
        
mysql_free_result($results);
    } else {
        
$results db_query("SELECT * FROM {$CONFIG['TABLE_USERGROUPS']} WHERE group_id = 3");
        if (!
mysql_num_rows($results)) die('<b>Coppermine critical error</b>:<br />The group table does not contain the Anonymous group !');
        
$USER_DATA mysql_fetch_array($results);
        
define('USER_ID'0);
        
define('USER_NAME''Anonymous');
        
define('USER_GROUP'$USER_DATA['group_name']);
        
define('USER_GROUP_SET''(' $USER_DATA['group_id'] . ')');
        
define('USER_IS_ADMIN'0);
        
define('USER_CAN_SEND_ECARDS', (int)$USER_DATA['can_send_ecards']);
        
define('USER_CAN_RATE_PICTURES', (int)$USER_DATA['can_rate_pictures']);
        
define('USER_CAN_POST_COMMENTS', (int)$USER_DATA['can_post_comments']);
        
define('USER_CAN_UPLOAD_PICTURES', (int)$USER_DATA['can_upload_pictures']);
        
define('USER_CAN_CREATE_ALBUMS'0);
        
mysql_free_result($results);
    }
}
// Test if admin mode
$USER['am'] = isset($USER['am']) ? (int)$USER['am'] : 0;
define('GALLERY_ADMIN_MODE'USER_IS_ADMIN && $USER['am']);
define('USER_ADMIN_MODE'USER_ID && USER_CAN_CREATE_ALBUMS && $USER['am'] && !GALLERY_ADMIN_MODE);
// Process theme selection if present in URI or in user profile
if (!empty($HTTP_GET_VARS['theme'])) {
    
$USER['theme'] = $HTTP_GET_VARS['theme'];
}
// Load theme file
if (isset($USER['theme']) && !strstr($USER['theme'], '/') && is_dir('themes/' $USER['theme'])) {
    
$CONFIG['theme'] = strtr($USER['theme'], '$/\\:*?"\'<>|`''____________');
} else {
    unset(
$USER['theme']);
}

if (
$_GET["cat"] == '15' ) { $theme='pocky'
   require 
"themes/pocky/theme.php"
   
$THEME_DIR "themes/pocky/"
} else { 

   if (!
file_exists("themes/{$CONFIG['theme']}/theme.php")) $CONFIG['theme'] = 'default'
   require 
"themes/{$CONFIG['theme']}/theme.php"
   
$THEME_DIR "themes/{$CONFIG['theme']}/"
}
// Process language selection if present in URI or in user profile or try
// autodetection if default charset is utf-8
if (!empty($HTTP_GET_VARS['lang'])) {
    
$USER['lang'] = $HTTP_GET_VARS['lang'];
}

if (isset(
$USER['lang']) && !strstr($USER['lang'], '/') && file_exists('lang/' $USER['lang'] . '.php')) {
    
$CONFIG['lang'] = strtr($USER['lang'], '$/\\:*?"\'<>|`''____________');
} elseif (
$CONFIG['charset'] == 'utf-8') {
    include(
'include/select_lang.inc.php');
    if (
file_exists('lang/' $USER['lang'] . '.php')) $CONFIG['lang'] = $USER['lang'];
} else {
    unset(
$USER['lang']);
}

if (!
file_exists("lang/{$CONFIG['lang']}.php")) $CONFIG['lang'] = 'english';
require 
"lang/{$CONFIG['lang']}.php";
// See if the fav cookie is set else set it
if (isset($HTTP_COOKIE_VARS[$CONFIG['cookie_name'] . '_fav'])) {
    
$FAVPICS = @unserialize(@base64_decode($HTTP_COOKIE_VARS[$CONFIG['cookie_name'] . '_fav']));
} else {
    
$FAVPICS = array();
}
// load the main template
load_template();
// Remove expired bans
$now time();
db_query("DELETE FROM {$CONFIG['TABLE_BANNED']} WHERE expiry < $now");
// Check if the user is banned
$user_id USER_ID;
$result db_query("SELECT * FROM {$CONFIG['TABLE_BANNED']} WHERE ip_addr='$raw_ip' OR ip_addr='$hdr_ip' OR user_id=$user_id");
if (
mysql_num_rows($result)) {
    
pageheader($lang_error);
    
msg_box($lang_info$lang_errors['banned']);
    
pagefooter();
    exit;
}
mysql_free_result($result);
// Retrieve the "private" album set
if (!GALLERY_ADMIN_MODE && $CONFIG['allow_private_albums']) get_private_album_set();

?>

Title: Different themes for different albums?
Post by: sintax on February 03, 2004, 12:19:06 am
Bump...

Anyone from the evening shift available to help?
Title: Different themes for different albums?
Post by: Joachim Müller on February 03, 2004, 12:24:36 am
http://coppermine.sourceforge.net/faq.php?q=lamesupport#lamesupport
Title: Different themes for different albums?
Post by: Casper on February 03, 2004, 10:07:21 am
ok,

change the cat number from '15' to the id of the one you want to change, and make sure the theme 'pocky' is spelt right and actually works.

Also remember, this will not work in the album pages, unless you add the album id's to the if function.
Title: Different themes for different albums?
Post by: sintax on February 03, 2004, 04:25:03 pm
Quote from: "casper"
ok,

change the cat number from '15' to the id of the one you want to change, and make sure the theme 'pocky' is spelt right and actually works.

Also remember, this will not work in the album pages, unless you add the album id's to the if function.


Casper... man you rock!
OK, can I ask one last favor? I want to add Album 10 for example... how do I do that? My code (snippit) looks like this so far:

Code: [Select]

if ($_GET["cat"] == '4' ) { $theme='pocky';
   require "themes/pocky/theme.php";
   $THEME_DIR = "themes/pocky/";
} else {

   if (!file_exists("themes/{$CONFIG['theme']}/theme.php")) $CONFIG['theme'] = 'default';
   require "themes/{$CONFIG['theme']}/theme.php";
   $THEME_DIR = "themes/{$CONFIG['theme']}/";
}


UPDATE:

Getting Errors now... Tried modifying the code to work with Album 10 but it isn't working.

Code: [Select]

if ($_GET["cat"] == '4' ) { $theme='pocky';
   require "themes/pocky/theme.php";
   $THEME_DIR = "themes/pocky/";
if ($_GET["album"] == '10' ) { $theme='pocky';
   require "themes/pocky/theme.php";
   $THEME_DIR = "themes/pocky/";
   }
}
else {

   if (!file_exists("themes/{$CONFIG['theme']}/theme.php")) $CONFIG['theme'] = 'default';
   require "themes/{$CONFIG['theme']}/theme.php";
   $THEME_DIR = "themes/{$CONFIG['theme']}/";
}
Title: Different themes for different albums?
Post by: Casper on February 03, 2004, 04:48:51 pm
OK, done it.

Go back to your first code;
Code: [Select]
if ($_GET["cat"] == '4' ) { $theme='pocky';
   require "themes/pocky/theme.php";
   $THEME_DIR = "themes/pocky/";
} else {

   if (!file_exists("themes/{$CONFIG['theme']}/theme.php")) $CONFIG['theme'] = 'default';
   require "themes/{$CONFIG['theme']}/theme.php";
   $THEME_DIR = "themes/{$CONFIG['theme']}/";
}


and change this;
Code: [Select]
($_GET["cat"] == '4' )

to this;
Code: [Select]
(($_GET["cat"] == '4') OR ($_GET["album"] == '10'))
Title: Different themes for different albums?
Post by: Nibbler on February 03, 2004, 04:53:16 pm
You've nested the second if inside the first if, make sure the {} are in the right places.

Probably better to just combine the 2:

Code: [Select]

if ($_GET["cat"] == '4' || $_GET["album"] == '10' ) {

   $theme='pocky';
   require "themes/pocky/theme.php";
   $THEME_DIR = "themes/pocky/";

} else {

   if (!file_exists("themes/{$CONFIG['theme']}/theme.php")) $CONFIG['theme'] = 'default';
   require "themes/{$CONFIG['theme']}/theme.php";
   $THEME_DIR = "themes/{$CONFIG['theme']}/";
}
Title: Different themes for different albums?
Post by: Casper on February 03, 2004, 05:03:09 pm
hi nibbler,

I'm just learning code myself.  I see you did this;

Code: [Select]
($_GET["cat"] == '4' || $_GET["album"] == '10' )

where I did this;

Code: [Select]
(($_GET["cat"] == '4') OR ($_GET["album"] == '10'))

So my question is, does this '||' do the same as 'OR'.  

And just what key do you type to get '|'  :oops:
Title: Different themes for different albums?
Post by: sintax on February 03, 2004, 05:13:26 pm
couldn't get either to work and then just deleted the file and started with a fresh one.... VIOLA!

Thanks both of you for the help. Is one suggestion better then the other? And if I want to add another album later on , do I just do something like this?

Code: [Select]
((($_GET["cat"] == '4') OR ($_GET["album"] == '10') OR ($_GET["album"] == '11')))

Or would the other suggestion with the "||" be better for when I wanted to add another album to it?
Title: Different themes for different albums?
Post by: Nibbler on February 03, 2004, 05:22:22 pm
Yeah, just use OR or || to combine them together, in this case it doesnt matter which you use.
Title: Different themes for different albums?
Post by: Casper on February 03, 2004, 05:24:03 pm
Glad you got it to work  :wink:

What you put would work, but I suspect Nibblers method is the more professional one, and will save on brackets.
Title: Re: Different themes for different albums?
Post by: olis on April 22, 2004, 10:53:21 pm
i tried this workaround and it works well until you wvote a picture.

then it change back to the predefined theme.

can anyone help ?

cheers

oli ???
Title: Re: Different themes for different albums?
Post by: hyperion on April 23, 2004, 01:30:11 am
Casper,

The primary difference between OR and || is that || ranks higher in PHP's order of operations.
Title: Re: Different themes for different albums?
Post by: olis on April 23, 2004, 07:52:50 am
but how can i ensure that the theme is not switching to the standart theme when you vote a picture ?

http://www.4riders.ch/bildgallery

when you choose the last category 'best trick' then it changes to green. until you vote for the picture everything is ok. as soon as you vote it goes back to standart theme

cheers

oli
Title: Re: Different themes for different albums?
Post by: Joachim Müller on April 23, 2004, 08:43:39 am
I don't have an answer to your question ready, but I wanted to give a remark on your index page: you have way too many items on it - you shouldn't display all album thumbs underneath the categories (set "Show first level album thumbnails in categories" to "no" in coppermine config) - you're using too many resources, and your index page takes ages to load.

GauGau
Title: Re: Different themes for different albums?
Post by: olis on April 23, 2004, 08:57:44 am
thanks for the tip. i know that there are way too much items. is there a way to add only one picture to the categories on the indexpage ?

Title: Re: Different themes for different albums?
Post by: Joachim Müller on April 23, 2004, 09:13:43 am
cpg1.3.0 will feature category thumbnails - if you feel comfortable with beta software you're encouraged to upgrade, but remember that there's no support yet for cpg1.3.0, as it's still in "beta" state.

GauGau
Title: Re: Different themes for different albums?
Post by: olis on April 23, 2004, 09:17:16 am
yeah i tested it allready but i could not get the videopart workign which is essentiel for us.

is there a way to embedd html code in the describtion, so i could take the pictures in like this.

but the other problem with the theme changeing is more important to me.

it's wired , isn't it ?

cheers

oli
Title: Re: Different themes for different albums?
Post by: globo on July 16, 2004, 03:32:08 pm
Hi I was wonering if it is possible to use a slightly different approach.

I want to use a different them for all "childs" or "sub-categories" of category X.

How would the if statement have to be?

if (requested category or album) is child of X then use theme Z instead of standard (Y)

Anyone got an idea?
Title: Re: Different themes for different albums?
Post by: AnnieB on March 07, 2005, 11:47:24 pm
I'm trying to set this, and it works, but I was wondering if there were a way of making the whole category be set with the same theme, instead of having to change init.inc.php everytime I create a new album

Any ideas?
Title: Re: Different themes for different albums?
Post by: kkapadia on November 19, 2005, 03:28:11 am
I was successful in being able to achieve a different theme for one particular catergory using the _GET["cat"], but as an earlier post suggested this works for only the category and not the albums below that category.

Is there a simple way to have use a different theme for the category and everything below without explicitly having to specify each album one by one?

Thanks for any help.