Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • eshealth Friend
    #173696

    Hi,
    I’m using JA CatSlwi module (JA_Sulfur template) in my website but I would the images I’m using were crop from the edge and not in center position.
    The module have a control panel that allow to customize differents parameters including if crop or not the images displayed.
    the problem is that the crop is only in the center part of the image (with a personalized dimension),there is a way permitting me start cropping from the right edge?
    Thanks all for attention.
    Tom


    1. JACatSIwi-parameters-panel
    eshealth Friend
    #437818

    Nobody helps me?!?…..no ideas?

    eshealth Friend
    #438690

    I found that!:
    How can I change this code for cropping from the right edge?
    [PHP]if ( $crop ) { // processing crop image
    $dst->w = $width;
    $dst->h = $height;
    if ( ($size[0] <= $width) && ($size[1] <= $height) ) {
    $src->w = $width;
    $src->h = $height;
    } else {
    if ($x_ratio < $y_ratio) {
    $src->w = ceil ( $width / $y_ratio );
    $src->h = $size[1];
    } else {
    $src->w = $size[0];
    $src->h = ceil ( $height / $x_ratio );
    }
    }
    $src->x = floor ( ($size[0] – $src->w) / 2 );
    $src->y = floor ( ($size[1] – $src->h) / 2 );
    } [/PHP]

    some php master here?
    thanks

Viewing 3 posts - 1 through 3 (of 3 total)

This topic contains 3 replies, has 1 voice, and was last updated by  eshealth 12 years, 8 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum