coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 themes/skins/templates => Topic started by: forester on July 04, 2007, 11:23:59 PM

Title: Cut full img width in html view
Post by: forester on July 04, 2007, 11:23:59 PM
I am using the Ipodlounge theme. Which is great for implementing in a website except that shows (like most themes do) full size image in displayimge in their full width and heigth if normal/middle images have been deactivated. And that breaks the theme if showing like > 2240x1280.
I want to "resize" full sized images showed in displayimage.php to a specific width. Fox example to the width of the ipodlounge theme.
This is done greatly in the Blix theme. I tried to handle it myself but still no effect.
Thank you in advance!  :)
Title: Re: Cut full img width in html view
Post by: Joachim Müller on July 05, 2007, 06:51:23 AM
The full-size image is being displayed in a pop-up anyway, I guess you're refering to the intermediate image that is being displayed embedded into coppermine. Post a link to your gallery for a start.
Title: Re: Cut full img width in html view
Post by: forester on July 05, 2007, 01:04:41 PM
Yes, I refer to intermediate images. The issue is that I have deactivated this option (intermediate) in the config due to low space. So, bigger images break the theme.

For example, http://media.hristobotev.org/displayimage.php?pos=-1079

What I want is just cut down the width of the full image to the template width saving the image proportions, of course. Like calibrating? I know it looks worse big images being shown as small, than with intermediates, but space is not enough.
Title: Re: Cut full img width in html view
Post by: Joachim Müller on July 06, 2007, 09:03:29 AM
Set "Max width or height of an intermediate picture/video (http://coppermine-gallery.net/demo/cpg14x/docs/index.htm#admin_picture_thumbnail_intermediate_dimension)" to something that makes sense. Even if you have disabled the creation of intermediate pics, the value you enter for the max intermediate dimensions is being taken into account for the HTML-resizing in displayimage.php
Title: Re: Cut full img width in html view
Post by: forester on July 06, 2007, 02:21:05 PM
It is set to 400 and I believe it hasn't been changed ever since installation  ::) For some reason, it obviosuly doesn't work for me  :-[
Title: Re: Cut full img width in html view
Post by: Joachim Müller on July 06, 2007, 09:03:27 PM
Doesn't happen when using another theme (e.g. http://media.hristobotev.org/displayimage.php?pos=-1079&theme=blix), so the custom theme you're using is overriding the config settings. Looking this up in the announcement thread of your theme (http://forum.coppermine-gallery.net/index.php?topic=27774.0) I couldn't find anthing related to the theme overriding the config settings. However, you appear to have modified the theme, so I suggest you zip your theme and attach it to your posting.
Title: Re: Cut full img width in html view
Post by: forester on July 06, 2007, 11:37:15 PM
Yes, it doesn't happen only in Blix and a couple of other themes.
But most of the themes work like the ipodlounge. I've just installed a clean fresh copy ipodlounge2 and it's no difference -
http://media.hristobotev.org/displayimage.php?pos=-1079&theme=ipodlounge2.
In fact, I haven't modified the theme.php in ipodlounge, but only template.html.


I noticed a "blix" method - theme_display_image, that the "ipodlounge" misses in its original theme.php:

function theme_display_image($nav_menu, $picture, $votes, $pic_info, $comments, $film_strip)
{
    global $CONFIG,$lang_picinfo;

//    $width = $CONFIG['picture_table_width'];
    $width = '455px'; - I believe this is the key row
   
    echo $nav_menu;

    echo $picture;
   
    if ($CONFIG['display_film_strip'] == 1) {
        echo $film_strip;
    }

    echo $votes;

    $picinfo = isset($_COOKIE['picinfo']) ? $_COOKIE['picinfo'] : ($CONFIG['display_pic_info'] ? 'block' : 'none');
    echo "<div id=\"picinfo\" style=\"display: $picinfo;\">\n\t\t<h2>{$lang_picinfo['title']}</h2>\n";
    starttable();
    echo $pic_info;
    endtable();
    echo "</div>\n";

    echo "<div id=\"comments\">\n";
    echo $comments;
    echo "</div>\n";

}
Title: Re: Cut full img width in html view
Post by: Joachim Müller on July 07, 2007, 09:32:18 AM
Do as I suggested if you want me to look into this: zip your custom theme (the entire folder "iploadlounge") and attach it to your posting.
Title: Re: Cut full img width in html view
Post by: forester on July 07, 2007, 12:02:21 PM
Here
Title: Re: Cut full img width in html view
Post by: forester on July 13, 2007, 11:38:22 AM
Any progress, GauGau?

Help much appreciated!
Title: Re: Cut full img width in html view
Post by: Joachim Müller on July 13, 2007, 04:29:44 PM
As expected, your custom theme.php interferes with $CONFIG values. Get rid of your custom function definition for theme_html_picture().

Joachim