Jetpack_Custom_CSS_Enhancements::jetpack_content_width PHP Method

jetpack_content_width() static public method

Override the content_width with a custom value if one is set.
static public jetpack_content_width ( integer $content_width ) : integer
$content_width integer Content Width value to be updated.
return integer
    static function jetpack_content_width($content_width)
    {
        $custom_content_width = 0;
        $jetpack_custom_css = get_theme_mod('jetpack_custom_css', array());
        if (isset($jetpack_custom_css['content_width'])) {
            $custom_content_width = $jetpack_custom_css['content_width'];
        }
        if ($custom_content_width > 0) {
            return $custom_content_width;
        }
        return $content_width;
    }