filmstrip current thumbnail? filmstrip current thumbnail?
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

filmstrip current thumbnail?

Started by DaBe, December 04, 2007, 08:55:04 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

DaBe


DaBe

sry I press enter...


my question:

How I can in the filmstrip give the current thumbnail another css-class than the other thumbs?

the current thumb must have a bigger border or whatever..


pls help...

Nibbler

Copy the theme_display_film_strip function from the sample theme.php to your custom theme.php and change this code in your copy:

find:


if ($mode == 'thumb') {


after it, add in a new line


if ($thumb['pos'] == $pos) $thumb['image'] = str_replace('class="image"', 'class="image middlethumb"', $thumb['image']);


Then apply the style in your stylesheet


img.middlethumb {
    border: 5px solid blue;
}

Joachim Müller

[ot]
@Nibbler&devs: imo this suggestion should go into the cpg1.5.x core. Thoughts?
[/ot]

Abbas Ali

Chief Geek at Ranium Systems

DaBe

nice one..thx

I have another question to the filmstrip thumbnails.

can I make the thumbs in the filmstrip with another attrribute then the normal thumbs..

I want display the filmstrip thumbs smaller then the normal thumbnails..


Joachim Müller

We have a "one question per thread" policy that you agreed to respect when signing up.

Joachim Müller

Committed suggested changes to SVN for cpg1.5.x, so this will be in the next version.

allvip

Quote from: Joachim Müller on December 06, 2007, 08:43:54 AM
Committed suggested changes to SVN for cpg1.5.x, so this will be in the next version.

it's not a cpg1.5 future but with some errors:

if ($thumb['pos'] == $pos && !$superCage->get->keyExists('film_strip')) {
                $thumb['image'] = str_replace('class="image"', 'class="image middlethumb"', $thumb['image']);


should be(because the fimstrip thumbnails class is .strip_image not image):


if ($thumb['pos'] == $pos && !$superCage->get->keyExists('film_strip')) {
                $thumb['image'] = str_replace('class="strip_image"', 'class="strip_image middlethumb"', $thumb['image']);


the css rules already are in the style.css (curve theme):


/* pseudo-classes for middlethumb links */
a:link .middlethumb,a:visited .middlethumb,a:focus .middlethumb,a:hover .middlethumb,a:active .middlethumb{
    border: 2px solid blue;
}

allvip

Quote from: allvip on March 25, 2014, 02:59:08 PM
it's not a cpg1.5 future but with some errors:

I meant: it's a cpg1.5 future but with some errors:

gmc

allvip,
Why are you replying to a 6+ year old post??
The code has clearly changed since then - so would certainly not apply to 1.5.
Greg
Thanks!
Greg
My Coppermine Gallery
Need a web hosting account? See my gallery for an offer for CPG Forum users.
Send me money

allvip

Quote from: gmc on March 25, 2014, 07:06:31 PM
allvip,
Why are you replying to a 6+ year old post??
The code has clearly changed since then - so would certainly not apply to 1.5.
Greg

Because I notice the error in sample/theme.php.I use the latest version of cpg.
Someone should adjust this in sample theme and include/themes.inc.php

and for users that find this topic and to not understand why the middlethumb class is not working.

The code has clearly not changed since then.

allvip

and because is a cpg1.5x future like Joachim Müller said but not working because the code has a very small error.

Proabibly cpg1.4x used class image for filmstrip thumbnails and nobody upated the code in the cpg1.5x filmstrip function.

The code for the middlethumb in filmstrip function (cpg1.5x) has class image not class strip_image just like cpg1.4x.

No need to start a new topic to say what I find out.

gmc

Quote from: allvip on March 25, 2014, 08:09:51 PM
and because is a cpg1.5x future like Joachim Müller said but not working because the code has a very small error.

Proabibly cpg1.4x used class image for filmstrip thumbnails and nobody upated the code in the cpg1.5x filmstrip function.

The code for the middlethumb in filmstrip function (cpg1.5x) has class image not class strip_image just like cpg1.4x.

No need to start a new topic to say what I find out.

I disagree... This post is 6 years old and in the 1.4 support board. If you have an issue with 1.5 - open a new thread in that board... You can certainly link here as the cause or for more more information... But someone searching the 1.5 board should be able to find a 1.5 issue.
Thanks!
Greg
My Coppermine Gallery
Need a web hosting account? See my gallery for an offer for CPG Forum users.
Send me money

allvip

Users that will find this thread like I did (I did not found another thread about current thumbnail) and read Joachim Müller post :"Committed suggested changes to SVN for cpg1.5.x, so this will be in the next version." will not understand why is not working if it is a cpg1.5x future now.

but fine I will post in cpg1.5x thread too.