Jump to content

Search the Community

Showing results for tags 'crop'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to ProcessWire
    • News & Announcements
    • Showcase
    • Wishlist & Roadmap
  • Community Support
    • Getting Started
    • Tutorials
    • FAQs
    • General Support
    • API & Templates
    • Modules/Plugins
    • Themes and Profiles
    • Multi-Language Support
    • Security
    • Jobs
  • Off Topic
    • Pub
    • Dev Talk

Product Groups

  • Form Builder
  • ProFields
  • ProCache
  • ProMailer
  • Login Register Pro
  • ProDrafts
  • ListerPro
  • ProDevTools
  • Likes
  • Custom Development

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests

Found 8 results

  1. Inspired by a recent question. Image Crop Ratios Allows preset aspect ratios to be defined per image field for the ProcessWire image crop tool. The module adds a select dropdown to the crop tool. Choose an aspect ratio and the crop area will be fixed to that ratio. Screencast Installation Install the Image Crop Ratios module. Configuration Default aspect ratios for all image fields can be defined in the module config. Aspect ratios for specific image fields can be defined on the Input tab of the field settings. You can override the ratio settings in template context if needed. Insert a hyphen as the first item in the ratio settings unless you want to force a ratio to be applied to the crop tool. The hyphen represents a blank option that allows a free crop area to be drawn. Usage Click the "Crop" link on the details view of an image thumbnail. Click the "Crop" icon at the top of the editor window. Choose an option from the "Ratio" select dropdown. https://github.com/Toutouwai/ImageCropRatios https://modules.processwire.com/modules/image-crop-ratios/
  2. I'm sure there was a way to manually crop an image within an Images field BEFORE you added it to a page? Am I imagining this? There was a small crop icon on the top right of an image and now it's gone. Possibly it's a result of changing an Images field to CroppableImage but I thought it may have been a bug?
  3. Far

    Image crop

    Hi, Recently i came across a strange behaviour of core image cropping function. My Core version is Dev 2.6.17, OpenServer (Apache 2.4, PHP 5.4 and PHP 5.6) I have an image like that: And when i try to crop it with that code: for($i=0;$i<=9;$i++) { $img = wire('pages')->get(1850)->page_header_images->eq(1)->crop(0, $i*80, 1280, 80); // crop($x, $y, $w, $h) echo "<img src=\"{$img->url}\"><br/><br/>"; } I get always get the same peaces of picture though it has different $y I also have a problem when i use resize/crop interface in modal window in page editor. I wanted to post n issue to github, but would like to ask you to check if you can reproduce this behavior
  4. I have an image 500x300 I need to apply the resizing to 150x150 without cutting edge. Thus in any case, I need to have the image canvas size 150x150 When you use $ image->size (150, 150), we obtain the desired result (cropping). When using $ image->size (150, 150, array ('cropping' => false)) our image circumcised according to the greatest height, canvas change proportionally. / / 150x90. Need an image 150x90 position in the center of the canvas 150x150. You can do this using the API?
  5. For example: It is necessary for you that all photos in galleries of "participants" would be in jpeg. But different types are allowed for loading, and all of them will be cut off in compliance with the type. I suggest to choose expansion in which the reduced copies of the image will be converted, it can be both control for a field, and expansion for API Image $image->ext() //jpg $newImage = $image->ext('png') $newImage->ext() //canonical png convert
  6. I'm attempting to make a photoblog type of site and was wondering if there's a clean way to get the image directory path when using the $image->size method. The purpose of this is so the user can upload their large images, display as a thumbnail and click to view a medium version no taller than 800px within a modal. As you can see, I've had to hardcode the site/assets/files directory. Is there another method? (*the getThumb function refers to another installed module) foreach($page->images as $image) { echo '<a href="site/assets/files/'.$page->id.'/'.$image->size('','800').'"><img src="'.$image->getThumb('thumbnail').'" alt="'.$image->description.'"/>'; }
  7. Am running into a problem where it seems using the ->size() method, my images are squeezing to fit rather than cropping. I though images would crop so as to maintain their ratio? Or perhaps it's too early on a Sunday morning to be looking at code Here is what I have: <!-- Main image --> <?php $main = $page->main_image->size(920,250); ?> <img src="<?php echo $main->url; ?>" alt="<?php echo $page->title; ?>" width="<?php echo $main->width; ?>" height="<?php echo $main->height; ?>" class="small_frame" id="main_image" /> <!-- Thumbnails --> <?php if ($page->images !="") { ?> <div id="thumbs"> <?php $images = $page->images; foreach ($images as $image) { $class = "thumb small_frame"; $thumb = $image->size(160,60); ?> <img src="<?php echo $image->url; ?>" alt="<?php echo $page->title; ?>" width="<?php echo $thumb->width; ?>" height="<?php echo $thumb->height; ?>" class="<?php echo $class; ?>" /> <?php } ?>
  8. I'm building a little photography portfolio site and I'm running into a question with image->size(). For most applications, the sizing to fit and center-crop is great, but for this site, I want to have a maximum width and maximum height, so that if the photo is narrower than the specified size, it gets smaller and has space on the sides, and if it's shorter, it gets space on the top and bottom. In other words, I'm looking to size the image such that it never gets cropped; you see the whole image even if it means making it smaller. Is there a way to do that with size()?
×
×
  • Create New...