Articles of content width

Why is WordPress serving the 1024px version of my image and not the original on a 1920×1080 screen?

I have uploaded an image that is 2100px wide into a post, and inserted that image in the post body. I’m building a custom theme based on WordPress’ Twenty Sixteen. The HTML looks OK: <img class=”alignnone wp-image-2669 size-full” src=”http://…/wp-content/uploads/2017/07/GrillSommer1.jpg” alt=”” width=”2100″ height=”904″ /> in the frontend, WordPress does what I assume is its “responsive image” […]

change the $content_width

I am creating a child theme based on 2016 I want to set new upload media images add_action( ‘after_setup_theme’, ‘azm_add_image_size’ ); function azm_add_image_size() { add_image_size( ‘helen’, 936 ); add_image_size( ‘brian’, 227 ); } add_filter( ‘image_size_names_choose’, ‘my_custom_sizes’ ); function my_custom_sizes( $sizes ) { return array_merge( $sizes, array( ‘helen’ => __( ‘helen’ ), ‘brian’ =>__( ‘brian’) ) […]

Display oEmbed in the_excerpt

I am currently adding add_filter(‘the_excerpt’, array($wp_embed, ‘autoembed’), 9); to my functions.php file to no avail any other suggestions would be great. Also if I add $content-width to functions.php the settings are ignored. I have wp-debug on with no errors/warnings and no errors are being logged.

$content_width for responsive UI

In our “mobile first” age a theme without responsive UI is treated like from stone age. It means that a theme could have different content width for different devices. But one of requirements for theme development is to provide $content_width variable which should contain actual width of content area of a theme. Taking in consideration […]

$content_width in “twentyfifteen.1.4” WP Default tHEME

if ( ! isset( $content_width ) ) { $content_width = 660; } The above mentioned code exist in wordpress Default Theme Functions.php on line#33 My Question: $content_width It looks like a global variable defined somewhere in core files in wordpress? $content_width=660; what is 660 is it in pixel. Actually which content width is this setting? […]

Can't extract and set SVG dimensions

Up to now, I have had no problems with the background-image thumbnails in my theme. However, now that I’m trying to use an SVG as the featured image, something is breaking. The problem seems to related to the width of the SVGs being returned as zero by wp_get_attachment_image_src(). So what I am I trying to […]