Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: styling categories (class="subcategory")  (Read 2977 times)

0 Members and 1 Guest are viewing this topic.

zro

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
styling categories (class="subcategory")
« on: August 05, 2005, 03:20:52 am »

http://art.redtv.org/gallery/

been styling/moding my coppermine. Hit a problem.

I can't seem to decipher the category function enought to give subcatgories a differnet (css) class.

I've seen this question asked a few times in different ways, but not answered (maybe im being an annoyance, sorry)...

it seems that there is some differentiation being as it adds
Code: [Select]
</td><td><img src="images/spacer.gif" width="20" height="1"></td><td>as {CAT_THUB}
for subcategories, but i cant seem to find where this is being processed....
(im new to php, and am currentally sucking down the manual... so sorry im ignorant.)

thanks!
Logged

zro

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: styling categories (class="subcategory")
« Reply #1 on: August 16, 2005, 11:35:15 pm »

well i found in index.php line 146
the mysterious
Code: [Select]
</td><td><img src="images/spacer.gif" width="20" height="1"></td><td>but im still a littl confused on how i can wrap sub categories in a


--code--
<div class="sub">
                <a href="index.php?cat=13">subcat</a>
                <span><b>1</b> files in <b>1</b> albums</span>
</div>
--code--


obviously i can change the above mentioned mysterious code (/td td spacer...etc) to the opening div.... but how can i add a trailing </div> if ($level > 1)

any ideas?

seen that some have differentiated sub and top-level cats w/ wrapped tags
i.e. here http://photos.edgladwin.com/
seems to have subcats wrapped in div and <small>....

...grrr. how do you do this? thanks in advance.
Logged

zro

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: styling categories (class="subcategory")
« Reply #2 on: August 17, 2005, 10:49:30 pm »

just tried adding this:
Code: [Select]

            if ($level > 1)
                       { get_subcat_data($subcat['cid'], $cat_data, $album_set_array, $level -1, $ident . "<div class=\"artsubcat \">");
            } else { get_subcat_data($subcat['cid'], $cat_data, $album_set_array, $level -1, $ident . "<div class=\"arttlcat \">"); }


in attempt to add div classes for each and every category based on "level" but i cant seem to get it to add to top level categories...
I tried $level < 2, =1, and finally this simple else.. but it doesnt seem to effect top level categpories.

the intention here was to add an opening div for everything and then close it later in the theme.php @ $template_cat_list =

i dunno if this is very efficent, but well, i cant even get it to work.... any ideas?
Logged
Pages: [1]   Go Up
 

Page created in 0.017 seconds with 20 queries.