1. Home
  2. Docs
  3. Greenlet Hooks
  4. Filters
  5. greenlet_content_width


apply_filters( ‘greenlet_content_width’ )

Filters maximum content width in pixels.

Content Width is a theme feature, first introduced in Version 2.6. Using this feature you can set the maximum allowed width for any content in the theme, like oEmbeds and images added to posts.

Using this theme feature, WordPress can scale oEmbed code to a specific size (width) in the front-end, and insert large images without breaking the main content area.

Example Usage:

function mytheme_content_width () {
	return 1000;

add_filter( 'greenlet_content_width', 'mytheme_content_width' );