Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [images]

Images are used in different ways by WordPress.You can use a theme with images in layout, place images within your post/page content, display images next to visitor's name called avatars etc

0
votes
0answers
12 views

wp_get_attachment_image_src calling wrong location

We are using the Exopite Simple Options Framework framework in our plugin. One of the fields is an image upload metabox: This works fine and images are uploaded and attached to the post as expected....
0
votes
2answers
18 views

Missing background image setting in admin of twenty nineteen

I have installed fresh Wordpress 5.0 with twenty nineteen theme. In admin panel for home page below colors setting a link to setting background image should be visible. See https://www.youtube.com/...
0
votes
0answers
8 views

Display Title/Description/Caption of custom images on homepage

I want to display the Title/Description/Caption of custom images on my homepage, here is the current code in functions.php file that only displays the image: <div class="partners-logoarea"> ...
0
votes
1answer
15 views

Add width & height attributes to Gutenberg’s image output?

Images inserted via Gutenberg don't have width & height attribute by default. I'd like to use those for lazy-loading purposes so image is positioned correctly. Is there a hook or something to ...
0
votes
1answer
12 views

Using ACF Pro plugin - How to get alt tags using repeater with Image ID? [duplicate]

I have the following code for calling the images in the slider but no idea on how to get the alt tag. I tried varied methods but I could be missing something. Please help. Possibly I am missing this ...
0
votes
0answers
8 views

How to dynamically call the alt text within WordPress? [duplicate]

I have this repeater field calling to an image but I also need to add the alt attribute that I added to each specific media file. Does anyone know how to do this? <img src="<?php ...
0
votes
0answers
9 views

Woocommerce shows product images in the wrong size

All products in my website have 200x200 featured images. But in catalog images are shown in 750x750 (sooo blurry) instead of 200x200. Source code of catalog page: <img width="200" height="200" src=...
1
vote
0answers
11 views

update_post_meta attachment_image_alt description for Gutenberg

I have resolve then 2016 with this solution update_post_meta for custom field not working upon form submission But for wordpress 5.0 with Gutenberg only in Media work, if upload the photo with block ...
0
votes
0answers
14 views

Media Library Not Working

The images in my Media Library are greyed out. When I attempt to put them into a page / post - they do not show up.
0
votes
0answers
11 views

Images with parallax effect [on hold]

It is the first time that I write in this forum of help so I apologize in advance for if I make an error. I would like to get in my photo gallery an effect of images with parallax effect that I have ...
0
votes
1answer
16 views

Featured image not shown in twitter post

I have a post with a featured image (size 736x212). The post url is this. I shared my post on twitter, but the tweet doesn't show the image (if you want to check click here). What could be the problem?...
0
votes
1answer
16 views

Why are my button images blurry on mobile screens?

I have a few custom buttons I've inserted with php throughout my wordpress site. They are crisp resolution images (either gif or png), but when viewing it on my iphone screen, they're blurry. I ...
0
votes
1answer
26 views

Serving images from subdomain & subpage - WordPress

I am serving images to my main site from subdomain. A link to the image now looks like that: static.example.com/2018/13/zdj.jpg/ I would like to add one more folder between domain and date, so it ...
0
votes
0answers
15 views

Help finding a plugin - masonry type post grid

I would like to know if there exists a similar plugin to how this page lists its' products below the main banner: https://www.ycmcnc.com/en Talking about this module: https://imgur.com/a/8IUalCQ It ...
-1
votes
1answer
20 views

How To Upload Wordpress Media Files On Subdomain With VestaCP [closed]

I got new server and install VestaCp on it and then i had created a wordpress blog let say mainblog.com and now i want to host media files from subdomain like media.mainblog.com, and for this I had ...
0
votes
0answers
12 views

Warning message on sensitive image

In a post with several big images, I'd like to put a warning message on some of them, so the user has to click on it to display the photo, as Twitter and Facebook do on some content. I haven't found ...
0
votes
0answers
18 views

Missing image size

I have added a couple of custom sizes to my wordpress environment with the following code: add_image_size( "maximal", "1900" ); add_image_size( "desktop", "1400" ); add_image_size( "tablet", "900" ); ...
0
votes
2answers
26 views

Wrong domain in uploads folder

I just changed my website's domain and the user profile pictures saved in wp-content/uploads/... still have the old domain in the url. Example: https://www.olddomain.com/wp-content/uploads/2017/10/...
0
votes
1answer
11 views

How to make cover image in post block expand to entire screen?

I want to cover the entire width of my page with the cover image block, the one where you can write on top of it. If I need to add a code, please provide the code as well for CSS class. Or is there ...
1
vote
1answer
40 views

How do I use <picture> element instead of <img> tags in WordPress post content having webP support?

I am developing my custom theme and trying to figure out how to modify the default code for WordPress image inserted into the post content, so I could add support for webP format and have it within &...
0
votes
0answers
25 views

How to get attachment URLs one by one, not in loop [duplicate]

<?php global $post; $args = array( 'post_parent' => $post->ID, 'post_type' => 'attachment', 'post_mime_type' => 'image', 'orderby' => 'menu_order', '...
-1
votes
0answers
20 views

How to get attachments outside loop [duplicate]

I want to display my attachments to outside the loop or one by one. I know I can insert images into post one by one where i want to show them in post. but i want to achieve this via php code as i need ...
1
vote
1answer
37 views

How to get next image with this code from same post?

I want to show images in my single-content.php file. I have almost 20 to 25 images in every post. I want to print them with below code one by one. I have to change one line in code for every image for ...
0
votes
0answers
17 views

“cropping” de l'éditeur d'image ne découpe plus les images

Here is my current configuration WP: Version of Wordpress: 4.9.8 Version of PHP / MySQL: 5.6 Used theme: ken 4.2 Extensions ready(in position): Name of the host: OVH Address of the site: https: // ...
0
votes
1answer
18 views

Dupplication of Custom Post Type while adding attachment

I'm facing an annoying issue that I can't solve. I've made this code in order to add or update an attachment on a custom post type : function add_update_attachment( $postID, $photo ) { if ($...
0
votes
1answer
16 views

Images showing up in Post Editor, but not in Published Post

I am trying to add three images by just inserting them into the post here: http://www.ihts.nl/wie-wij-zijn/ Although I can see the images perfectly in my Media Library as well as in the post editor ...
0
votes
1answer
14 views

Is there a possiblity to replace profile image gravatar with custom user images

Is there any possibility to replace gravatar session in profile page with an custom image with their image. Which can be uploaded from their PC while creation of the account is is possible to do with ...
0
votes
0answers
11 views

How to select all images from a folder and display them in admin area?

This code works on my localhost, but when I install the plugin on live website, I have to do some changes. Is there a way to write something that will work on any WP website? The problem is path... ...
0
votes
0answers
24 views

Full width header image for pages

Is there a way to insert a full width image for pages? I'm using Astra theme, and when I use the following code, it appears in the home page also (on top of the home page slider) .site-header { ...
1
vote
0answers
45 views

Add custom CSS class to product images

I would like to add a custom CSS when displaying product images. E.g. when calling the woocommerce_get_product_thumbnail function. I've tried solutions like this: Add CSS class to every image but ...
1
vote
1answer
33 views

Auto delete pictures in media library by age

I want to auto delete images in the media library that are older than 3 days. Is there a method to do this?
0
votes
2answers
62 views

Images not showing in media grid view (but showing in list view)

In my Wordpress install, thumbnail images are not showing in the media library, when in grid view. They are showing when in list view. In addition, if I once request a thumbnail directly, in the ...
0
votes
1answer
20 views

limit amount of photos uploaded per cpt post

On my site I have a front end form for users to create a post and upload images. It works fine however I cant seem to figure out how to limit the number of images per post. The image attachments get ...
0
votes
0answers
15 views

Jetpack : skip lazy loading on some images

I didn't find any solution to this, so I share my findings: add skip-lazy class to your image, it will be excluded from lazy loading. Eg: <?php the_post_thumbnail('post-thumbnail', ['class' => '...
0
votes
0answers
14 views

I can't upload new picture keeping an old name

Maybe the title confuses a little, but here's my problem: I worked with some images to create a banner, uploading them through the Media section in the WP dashboard. Now I want to change one image ...
0
votes
0answers
18 views

baguetteBox with wordpress

I am using baguetteBox with WordPress and I have an issue and I can't get where the problem is. Every time the page load, I click the first image and it works well and it opens in the popup the modal ...
0
votes
0answers
31 views

How to add php to theme to show alt attributes

I am trying to figure out how to add PHP / code to my template so that my alt tags show up for my images. The theme has been modified by a company that is no longer around so I can't ask how to ...
0
votes
1answer
19 views

Images do not show in the website, but they appear on new tab

I am new to wordpress. I updated my wordpress website to the current version since I did not take care of it since 2013. However, after I updated it, my images do not appear on my website anymore. ...
0
votes
1answer
13 views

Images missing from Blog post page

I have created a blog named Tutsguru. When i visit Main page it shows feature images of blog post but when i visit Blog page then images are not shown. I tried different browser but same problem. Can ...
1
vote
0answers
48 views

Get all post media images via WP REST API

We want to build a back-end for a mobile app using WordPress. We are trying to get all post images, but when we call https://api.com/wp-json/wp/v2/media?parent=58 we are getting only the first image ...
0
votes
1answer
14 views

Page size too big due to images

I hope it's a fitting question to be asked here. My website loads the images and then resizing them. So what happens is the image is loaded full sized and then reduced. I have lots of images already ...
0
votes
1answer
36 views

How to fix broken media library?

I asked this question and got no help at Wordpress.org. Here it is: Hi – Got a strange problem. When I go to my Media Library, I can’t see any of the images: Screenshot: https://postimg.cc/gallery/...
0
votes
1answer
13 views

After moving a site to new hosting, not all images are showing in media library

I have moved my website to new hosting. The site was originally in public_html/websites/dcworldholding/newsite on my server, on the new server its in public_html/ Some images are showing but the ...
0
votes
1answer
15 views

How to allow multiple thumbnail upload for Posts?

Here's the deal: I was migrating the content (lots of posts) from an old site to a new one. The posts have multiple images attached to it (which I've noticed when I was importing the thumbnail images ...
0
votes
0answers
20 views

Generate_Featured_Image not working

im trying to use the function "Generate_Featured_Image", to set feature image to some post, ive created a api on my wordpress site, and im sending a external curl request from another site with link ...
0
votes
0answers
12 views

Displaying images in WordPress without storing image data in database

I am working on a site with more than 10.000 products that are stored as a custom post type. The products are imported each week with a custom import script that places the right information on the ...
0
votes
0answers
16 views

Error HTTP with Imagick on functions.php

When I upload jpg/png or mp3 files WordPress get ERROR HTTP. I have the following code on my functions.php: function register_watermarked_size() { add_image_size( 'watermarked', 550, 550, true ); //...
1
vote
1answer
18 views

IMG src weird behaviour inside a single post loop

I was trying to sort out the final look the featured image of a single post, so for the purpose wanted to add a class to the img tag. However on the way, I run into some weird behaviour while trying ...
0
votes
1answer
25 views

Add attribute only to first image of every post via functions.php

I would like to use a simple function in order to add a specific attribute (lets call it “example”) to the first image of every blog post, so that I don't have to do it manually in thousands of posts. ...
0
votes
0answers
10 views

How to style Image and Gallery Output for AMP?

So, I am trying to create a custom AMP template for my website without a plugin. Here's where the problem is. I am using a single-amp.php to redirect /amp posts to the AMP template. I have then used a ...