Skip to content

Instantly share code, notes, and snippets.

@regenrek
Created August 12, 2016 13:27
Show Gist options
  • Save regenrek/e79dea9e000457b409e9dd3f7df4e33c to your computer and use it in GitHub Desktop.
Save regenrek/e79dea9e000457b409e9dd3f7df4e33c to your computer and use it in GitHub Desktop.
Wordpress Easy Inline Image Resize
# install https://github.com/regenrek/WP-Aqua-Resizer Wordpress plugin
$att_id = get_post_thumbnail_id(get_the_ID());
$image = aq_resize(wp_get_attachment_url( $att_id ), 400, 400,true, false); ?>
<img src="<?php echo $image[0]; ?>" alt="img" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment