Plugin Directory

Get the perfect image size at any given point in your theme!

This plugin hasn’t been tested with the latest 3 major releases of WordPress. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.

Get the perfect image size at any given point in your theme!

Description

flyimage allows you to specify the image size you would like to receive in your Themes HTML!
The file will automatically be created on a first visit. Further visits will use the already created file.
Cached images will be stored in your uploads Directory (usually wp-content/uploads/fly/)

Single Image

flyImage($attachmentId / $attachmentUrl, $width, $height)

Example: Image with a width of 200px

<img src="{{ flyImage(1, 200) }}" />

Example: Image width a width of 300px and a height of 200px (cropped)

<img src="{{ flyImage(1, 300, 200) }}" />

Example: Image width a width of 300px and a height of 200px (uncropped)

<img src="{{ flyImage(1, 300, 200, false) }}" /><h3>Get a full SourceSet</h3>

flyImageSourceSet($attachmentId / $attachmentUrl, [$width1, $width2, …])

Example: Sizes: 400px, 800px and 1200px (width):

<img srcset="{{ flyImageSourceSet(1, [400, 800, 1200]) }}" />

Reviews

Read all 1 review

Contributors & Developers

“Get the perfect image size at any given point in your theme!” is open source software. The following people have contributed to this plugin.

Contributors