2022 Developer Survey is open! Take survey.

Questions tagged [content-width]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
18 views

Change page width in refined magazine/mag and news theme

I am using Mag and news theme, which is a child theme of Refined Magazine. On the admin page, there seems to be no option of changing the page width. I am capable of editing php files as well, but I ...
user avatar
0 votes
0 answers
28 views

Display of content does too wide for screen

On my 15.5" laptop, my website content width is displayed across-- off the screen. Maybe caused by PHP update last week. Noticed first on preview of new post, then when published. Old posts fit ...
user avatar
  • 1
0 votes
1 answer
41 views

What is the use of $content_width?

In the requirements of Envato I saw that they require a $content_width to be set. I searched for it on the internet but can't really understand why? I don't use it and the theme is responsive. If ...
user avatar
0 votes
1 answer
40 views

Mobile view: how to remove right/left margin from the specific widgets?

May I know how to remove right/left margin from the bottom two parts(Lessons and Fees,Contact) of my website on phone? It seems ok on PC but not on phone. Especially the table for prices lookes ...
user avatar
  • 1
0 votes
1 answer
284 views

How to change the content width using php?

I've created a custom template using php and would like to know how to modify the content width? Do I have to create a class within php and then modify the width using CSS? This is how my php ...
user avatar
  • 1
0 votes
1 answer
565 views

Gutenberg blocks not full width

I am having an issue where an image block in Gutenberg editor is not the full with of the page even though I have selected "Full Width" in the back-end. Is there a way to fix this? Image for ...
user avatar
2 votes
1 answer
512 views

Define multiple Gutenberg editor widths

I'm trying to define multiple widths for the Gutenberg editor depending on the post/page template. I have a full-width page template and would like the editing experience to be as close to the live ...
user avatar
  • 105
0 votes
0 answers
90 views

TwentySeventeen $content_width not updated in admin

I've read many answers to the problem of modifying TwentySeventeen's content width, but this one aspect is eluding me. I have the following in my child theme's functions.php function ...
user avatar
  • 131
-2 votes
2 answers
2k views

How do I get both horizontal and vertical scroll bars in an HTML texbox

I have an issue that I can find how to setup vertical scroll-bars but not horizontal scrollbars. A couple of demos are at: https://www.w3schools.com/TagS/tag_textarea.asp https://stackoverflow.com/...
user avatar
1 vote
3 answers
704 views

Why is Wordpress serving the 1024px version of my image and not the original on a 1920x1080 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="...
user avatar
  • 502
0 votes
0 answers
28 views

How to set one white space as width as one character in wordpress?

My wp theme is twentyfifteen ,font in style.css is inherit,the font in firefox is noto mono. I found that one white space is as width as one character in wordpress development--this forum,two white ...
user avatar
  • 103
7 votes
2 answers
5k views

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 ...
user avatar
-1 votes
1 answer
1k views

what is the width of my blog column? [closed]

My blog is voraciouslyyours.com I would like to know the width of my blog column. I have been told that I should make images "twice the width of my clog column" because the retina screens need the ...
user avatar
  • 17
1 vote
1 answer
50 views

How to set a correct $content_width when there are two content widths on one page?

Currently I have 1860px wide image as featured image which shows on top of a post page, and 800px as post content width, and when I Set $content_width = 800 The featured image shows as 800px wide ...
user avatar
  • 409
1 vote
1 answer
527 views

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', ...
user avatar
  • 151
6 votes
1 answer
223 views

$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 ...
user avatar
1 vote
0 answers
32 views

Unable to edit the "customize" section and the "widget" section is populating unknown code

My WordPress site is experiencing some major issues. I am getting a 500 server error when attempting to change the "customize" side bar, and the "widget" section is acting really weird (populating ...
user avatar
-1 votes
1 answer
291 views

Set add_image_size() greater than content width in media box

How can I set a image size bigger then the defined max content width in the media box? The content width is set to: if ( ! isset( $content_width ) ) { $content_width = 960; } If I add now a ...
user avatar
  • 147
0 votes
1 answer
25 views

Figure inlined width trigger distorted layout

I recently changed my theme to completely new one (fresh), and all my post images suddenly started to break my layout. When I inspect code all images and loaded content that are wrapped in 'figure' ...
user avatar
1 vote
1 answer
1k views

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 ...
user avatar
-1 votes
2 answers
2k views

Change featured thumbnail based on screen size

My theme has the option( like any other theme I guess) to chose a predefined featured image size( thumbnail, medium ...etc). I chose the image to be thumbnail, made it 150x150 in media settings but my ...
user avatar
1 vote
1 answer
132 views

Is it possible to create a conditional for content_width?

Searching here I've found two questions related and at the time, this wasn't possible. how to create a conditional content_width for a wordpress theme? And an alternative way via CSS described by ...
user avatar
0 votes
1 answer
601 views

Truncate title to single line & container width

Is there a way to truncate a title to the container width? I'm able to do truncate a long title to one line using the code below, but that doesn't really work for mobile. <h3> <?php ...
user avatar
  • 173
2 votes
1 answer
2k views

$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 ...
user avatar