Support

Account

Home Forums Add-ons Repeater Field Image resize after upload

Solved

Image resize after upload

  • Hi,

    I’m uilding a site with acf, everything works good, documentation is very good but I’m stuck at one problem: I need to resize (not with css) the uploaded images via repeater field.

    Do you guys have some idea how can I do this?

    Thanks.

  • Hi,

    Can you not use TimThumb? This is what I do and it works really well!

  • sure, i can use thimthumb, but could you give me an example?

    thanks 🙂

  • Sure.

    I’ve installed the timthumb code in its own directory within my theme.

    I then have a field within my repeater called image

    Finally, I have a line of PHP ($theme_path) which I call from my function file. This is simple the path to timthumbs files like so:
    $theme_path =’http://www.domain.co.uk/wp-content/themes/theme_folder/’;

    <img src="<?php echo $theme_path; ?>timthumb/timthumb.php?src=<?php the_sub_field('image'); ?>&w=618&h=298&q=100">

    That should get you what you need. Hope that helps

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

The topic ‘Image resize after upload’ is closed to new replies.