Articles of images

Display number of images actually posted

I’m currently using this PHP code to pull the number of images from a post. $attachments = get_children(array(‘post_parent’=>$post_array[0][‘ID’])); $image_count = count($attachments); It is currently pulling any image that is “attached” to the post, however I would like for it to pull the actual number of images that were used in the post. How would I […]

Get URLs for All Sizes of Image via Admin Panel

We want to use wordpress to host image which we’ll use in our email newsletter. To that end, we can obviously upload the image via the Media panel in Admin and either right-click the image and get URL or enter Library and click the image to see the URL in the details area. Then we […]

Why images/photos after being uploaded to my wordpress site get slightly blurry?

I am trying to figure out the problem stated in the title. Every image/photo I upload to my wordpress site gets slightly blurry. I format them according to my wp theme requirements, however after the image is processed by wordpress and I open the site in a browser I is slightly blurry. This is specially […]

Bulk image rotation

I have just uploaded around 70 photos from Windows 10 into wordpress. While all of those photos in Windows are presented correctly WordPress does not recognize their proper rotation. I may use wordpress media library to rotate each image one by one but this would take hours. Do you know any plugin or way to […]

How to add a rel attribute to images that contains their categories?

I’ve added categories to images, so that I can use them to filter images within a portfolio page. Now I’m thinking I need to add the rel attribute to each image that contains its assigned categories. Is this the right approach? If so, how do I add add rel with the applicable categories?

Populate a slideshow list of images from images in a wordpress page?

I’m using the “flexise” slideshow script to automatically scroll a list of images. The list is hard-coded along with the script in a wordpress template page. While this works fine, how could you make it so that the slideshow pulled any images added to a special (private) wordpress page instead of having to add each […]

How to get custom image size for image uploaded in Customizer

I’m using the customizer to upload an image. The code I have below displays the full size image ok but I would like to instead display a custom size of that image that I created below that. This is the code in my template file: <img src=”<?php echo get_theme_mod( ‘image-1′ , get_template_directory_uri().’/images/default.jpg’ ); ?>”> This […]

How to add a random image to a post from gallery and only show one?

I know how to add an image and a gallery. I need to have one image from the galley show on the page at random each time the page is loaded. The page should only show one image at a time. Is there a plugin or short code to do this? I know how to […]

How to display post title & excerpt when mouse hovers on an image?

I am bit busy with developing one fashion website, currently (, where I have images come from posts and when mouse will hover on any image, the corresponding post title and post excerpt will de displayed. Couldn’t make it happen though 🙂 Any clue will be helpful. Site is developing in wordpress enviornment, so any […]

How do I set the default “feature image” size?

I know I can set up post, pages, and custom post types to use featured images in wordpress by enabling theme support: add_theme_support( ‘post-thumbnails’); Or enabling theme support for a specific set of post types: add_theme_support( ‘post-thumbnails’, array(‘post’,’page’)); I also know that I can add an “image size” like this: add_image_size( ‘media_library’, 333, 230, true […]