select exact size of uploaded images
-
Hi, i’m having some problems in getting the url of custom sizes images.
I have a custom sized image type, named dimension-gallery (hard cropped, 800×533).
I’m trying to get the url formatted in this way:
wp-content/uploads/2013/09/photo-800×533.jpg
But no luck.
I’m using:<?php $imgs = get_images_src('dimension-gallery', true); foreach( $imgs as $i ) echo '<li style="background-image: url('. $i[0].');">></li>'; ?>
but it points to the uncropped-original url (wp-content/uploads/2013/09/photo.jpg)
if i echo $i[1].$i[2] the result is 800533 , correct;
anyway i can’t get the desired url
Thanks
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘select exact size of uploaded images’ is closed to new replies.