TimThumb Featured image & Thumbnail crop positions

pending (9 posts) (3 voices)

  1. Hi guys,

    This is my first time using a mysitemyway theme and I am really impressed so far!

    I have a quick questions as I cannot source the php that adds the timthumb cropping code to individual images.

    Currently thumbnails and featured images are being squashed, ideally i don't want to re-size the image, but just have the image be aligned to the top left of the bounding box.

    Does this make sense? I have done this with themes in the past.

    I'd really appreciate it if someone could point me in the right direction :)

    Thanks

    Posted 6 months ago #
  2. Just a quick update, if I go to thumb.php and edit the normal settings this is not having an effect.

    From

    $zoom_crop = (int) get_request ('zc', 1);
    $align = get_request ('a', 'c');

    To

    $zoom_crop = (int) get_request ('zc', 0);
    $align = get_request ('tl');

    All help appreciated

    Posted 6 months ago #
  3. Ruderic
    Support

    Hi,

    Go to the theme folder and open the file "lib/functions/images.php". In line #184 you will find this code:

    $image = THEME_URI . '/lib/scripts/thumb.php?src=' . mysite_wpmu_image( $src ) . '&w=' . $width . '&h=' . $height . '&zc=1&q=100';

    Replace it with:

    $image = THEME_URI . '/lib/scripts/thumb.php?src=' . mysite_wpmu_image( $src ) . '&w=' . $width . '&h=' . $height . '&zc=0&q=100&a=tl';

    Try that and let us know the results.

    Posted 6 months ago #
  4. Hi,

    thanks for the fast response, I have just tried changing this, cleared my cache etc and it hasn't worked :(

    Here is a link to one of the pages that is being squished: http://bit.ly/uz18zB

    I tried changing both the "Standard input properties" in thumb.php & the line you suggested, together and individually but it hasn't worked.

    To re-iterate, all I want is the images aligned TOP, LEFT and not to be zoomed in.

    Thanks :)

    Posted 6 months ago #
  5. Elliott
    Support

    Hello webwalker,

    If you do not want the image to be resized then you'll need to crop the image before uploading so that it fits the container.

    From your link that appears to be a single post featured image. You can find the dimensions in Dashboard -> your theme -> Image Resizing in the "Image Sizes for Right Sidebar Layouts" section. What your looking for is the "Single Post Image" dimensions.

    Posted 6 months ago #
  6. Hi Elliott,

    Sorry been off this project for a little while now.

    I don't think that the issue is re-sizing, more of what is actually being displayed.

    I have set up a new post using a Circular Test image: http://bit.ly/sMEUYe

    As you can see the featured image is horribly squashed.

    What I want is for the image to be aligned to the top left of the box, even if the image's bottom side etc isn't visible.

    I know that the TimThumb script is capable of this as I have it running on many other sites.

    Thanks for

    Posted 5 months ago #
  7. Elliott
    Support

    In your link the image is not being resized when it should be. Did you disable image resizing?

    Posted 5 months ago #
  8. Hi, no image re sizing should be on. I have not changed any of the core theme files for that either :(

    Here is a screenshot of my image re-sizing settings: http://screencast.com/t/oXzmcn3Ym3

    Posted 5 months ago #
  9. Elliott
    Support

    Go ahead and create a backup and reinstall the theme, deactivate all plugins, and then send us a private message by clicking on the "PM this user" link beneath our usernames and we'll take a closer look.

    Be sure to include a link to your page and a Wordpress login.

    Posted 5 months ago #

Reply

You must log in to post.

Construct WordPress Theme
Construct wordpress theme
Myriad WordPress Theme
Myriad wordpress theme
Method WordPress Theme
Method wordpress theme
Fusion WordPress Theme
Fusion wordpress theme
Elegance WordPress Theme
Elegance wordpress theme
Echelon WordPress Theme
Echelon wordpress theme
Dejavu WordPress Theme
Dejavu wordpress theme
Modular WordPress Theme
Modular wordpress theme