Have you tried to add the background size “cover” inline as well, like so
<section class="hero" style="background: url('<?php echo $hero_image['url'];?> ') cover;" xmlns="http://www.w3.org/1999/html">
Related Posts:
- @wordpress/create-block image url in css
- How to change background image
- change with CSS the color of an svg background image set with “background-image: url()”
- How to reference a theme image in a stylesheet?
- Making WordPress Gallery (.gallery-item) Responsive?
- Adding HTML within an image title attribute
- Width 100%: Aspect ratio of image
- Add CSS class to every image
- How to Make WordPress Default gallery responsive on mobile?
- Responsive background images added inline
- How can I upload an image for background use using the Theme Editor in WordPress?
- Override img class in gallery
- Multiple amp-image overlays. How to properly do this in wordpress?
- Image not shown in the theme as it’s showing in HTML template [closed]
- Background-image not showing? [closed]
- t5-fresh-editor-stylesheets.php breaks image placement in WP Beta 3 editor
- Custom header tiling?
- Using featured img as div background
- How do I get my main image to stretch the full length of the screen?
- Different background images on different sites [closed]
- HowTo: develop WP template with dynamic background image
- How to upload and style svg logo?
- How would you add sequentially numbered labels to images in posts?
- css to fit image by HEIGHT
- How to implement CSS-defined images from bootstrap site in wordpress theme
- a: hover issue with image issues [closed]
- All 3?: Responsive resizing of images + image width of actual image for small images + max-width for all larger images
- Moving an image to the side [closed]
- Random home page background images with caption text
- Image Captions Have a 10px Extra Margin, And It’s Not CSS? [duplicate]
- Can i have 2 separate Galleries on 2 separate pages each go to a DIFFERENT Attachment.php file?
- Image modification
- How to remove image size inline style in article and include caption
- Is there a layout to place 2 same sized images in two columns on the WordPress page?
- Fullscreen Page Background without Plugin [closed]
- Landing Page with HTML CSS JS and Images on wordpress
- I would like to set a FULL SCREEN background image to all my pages (same way it is on my home page)
- Change header image size
- Adding custom html/css/images to Theme
- Is there a way to create referable automatic numbering in image captions?
- Custom Background for each page and post
- Why do images inserted in the post content via the_content() go off the max-width?
- How can we achieve this image css style?
- Remove image border in twentyeleven theme [closed]
- How to display posts with images in fullscreen slider
- Using a full-width hero image that can be changed in the dashboard by a user
- Put image onto header
- Are WP images responsive by default?
- Image thumbnail on single product issue | WooCommerce
- Background image call problem
- all images of past post messed up after changing theme
- Custom styling Insert Media window
- Display ajax preloader for large images within posts
- An image on my site is showing as the wrong image [closed]
- Theme files and imagesnot loading on a mobile device
- Is there a good way to use CMS images with CSS
- Stop underlining image links
- Font size on image captions on mobile
- Parallax image problem
- Theme using masonry layout script rendering overlaped images in Google Chrome [closed]
- Why is inline CSS added to images automatically? [closed]
- Create decorative image border with CSS? [closed]
- Placing a background image with text over it
- WordPress update leads to 404 error on admin page and signup. CSS mishap with all plugin related functions
- I am having trouble displaying an image at the top of a widget area [closed]
- Is there a way to add background-image to theme.json?
- CSS how to target the caption of one individual image?
- How do I set attributes for all images in a site
- css and images in uploaddir, different response in different browsers
- How to make an image appear then another takes its place and so on?
- WP Large Images crash page
- Generate links on all images in posts – is there a hook?
- Why image Thumbnail url is not displaying with custom size?
- Decide how Hero image appears on mobile
- Can i use my Old Post image URL in my new post?
- Exclude first image from a Woocommerce image gallery
- Responsive Featured Images Not Working
- Recovered WordPress installation (on localhost) links broken and images not showing
- Responsive images with srcset
- Image is missing on site homepage
- get_image_tag & wp_get_attachment_image_attributes behaving strangely
- Fetch customizer image and output as an inline css style background image
- How to bulk update then save images in wordpress posts
- Images not loading on wordpress.org site
- Using WP 4.9.6 and big trouble showing images
- Blank image thumbnails in media library
- Getting extra image links in code with wp_get_attachment_image
- How to disable post-thumbnail from generation?
- How to set a post featured image from an already made custom field
- Load only imagens resized in custom page
- How to compress thumbnails instead of cropping
- js alert in add_filter function for image_send_to_editor
- featured image in custom poste type (backend)
- How to find the largest images in wordpress post
- Post Images are not showing up whenever I use shortCodes in my posts
- Custom image sizes quality
- How to inject alt and title attributes for every image in each post into HTML?
- built-in responsive images in content – do I need to add anything to functions.php?
- Why does wp_get_attachment_image_src return the wrong size, when the correct size exists?
- Text not wrapping properly around image in WordPress Visual Editor [closed]