Horizontal scrolling images rescale

steverobertson / 2012-09-21 10:38:23   

Hi All

In he last version i used to have my site set so that no matter what res the users browsers were, the images would scale to the height of it, thus filling the screen with ithe image/images

I cant seem to find a way of doing it with this version... can anyone ghelp?

It would be much appreciated

Thanks

Steve

steverobertson / 2012-09-21 23:51:25   

I have found what i think was the file that made it work previously...its called

exhibit.horizontal_sized.php

anyone know if there is a new version for this or if it can be used with the new indexhibit?

here is the code

/**
* Horizontal Format
*
* Exhbition format
* Originally created for SharoneLifschitz.com
*
* @version 1.1
* @author Vaska
*/

$DO = new Horizontally;

$exhibit['dyn_js'] = "

function resizeit() { showHeight('document', $(window).height());
function showHeight(ele, h) {
$('.picture img').css( 'height', h -30 );
$('#img-container').css( 'height', h -30 );

    }
var    sum = 0;
$('.picture img').each(function()
{
sum += $(this).width() +21;

});
$('#img-container').width( sum );    
}

$(window).resize(function() {

resizeit();
});

$(window).load(function(){
resizeit();
    });
    
    

";

$exhibit['exhibit'] = $DO->createExhibit();
$exhibit['dyn_css'] = $DO->dynamicCSS();

class Horizontally
{
    // PADDING AND TEXT WIDTH ADJUSTMENTS UP HERE!!!
    var $picture_block_padding_right = 50;
    var $text_width = 250;
    var $text_padding_right = 75;
    var $final_img_container = 0; // do not adjust this one
    
    function createExhibit()
    {
        $OBJ =& get_instance();
        global $rs;
    
        $pages = $OBJ->db->fetchArray("SELECT *
            FROM ".PX."media, ".PX."objects_prefs
            WHERE media_ref_id = '$rs[id]'
            AND obj_ref_type = 'exhibit'
            AND obj_ref_type = media_obj_type
            ORDER BY media_order ASC, media_id ASC");

        if (!$pages) return $rs['content'];
    
        $s = ''; $a = ''; $w = 0;
        $this->final_img_container = ($rs['content'] != '') ? ($this->text_padding_right + $this->text_width) : 0;

        foreach ($pages as $go)
        {
            $title = ($go['media_title'] == '') ? '' : "" . $go['media_title'] . "";
            $title .= ($go['media_caption'] == '') ? '' : "" . $go['media_caption'] . "";
        
            $temp_x = $go['media_x'] + $this->picture_block_padding_right;
            $this->final_img_container += ($go['media_x'] + $this->picture_block_padding_right);
        
            $a .= "n";
            $a .= "n";
            $a .= "n";
            $a .= "$titlen";
            $a .= "n";
            $a .= "nn";
        }         $s .= "n";
        if ($rs['content'] != '') $s .= "" . $rs['content'] . "n";
        $s .= $a;
        $s .= "";
        $s .= "n";
        
        return $s;
    }

    function dynamicCSS()
    {
        return "#img-container { width:30000em; margin-top:0px; padding-top:0px; }
#img-container #text { float: left; width: " . ($this->text_width + $this->text_padding_right) . "px; }
#img-container #text p { width: " . $this->text_width . "px; }
#img-container .picture_holder { float: left; }
#img-container .picture img { padding-right:20px;}
#img-container .captioning .title { margin-top: 12px; font-weight: bold; }
#img-container .captioning .caption { }
";
    }
}

arsondpi / 2012-09-22 07:05:04   

Unfortunately no - it needs to be updated since this works only with the Legacy version. I found this script on the web: aaronvanderzwan.com/maximage/… - if you manage to customize it and to get it to do what you're after you might have a good chance solving this.

steverobertson / 2012-09-23 21:20:36   

Hi

Thanks for the reply, unfortunately my skills dont really allow me to work on that... if anyone wants to give me a cost to get this plugin to work on the new version then please let me know

thanks

steve

fransvax / 2012-10-01 20:31:55   

Yes, exact same issue here! It would be great if this could work on the 2.0 version.

Thanks

Francois

hausgrafik / 2012-10-01 21:00:21   

Yes, exact same issue here as well!

Would be very nice!

Urs

serge70 / 2012-10-02 14:14:40   

I'm struggling with the same problem.

Cheers,
Serge

This thread has been closed, thank you.