Forked from lots0logs/child-theme-functions-php-snippet.php
Created
April 2, 2017 13:53
-
-
Save langlers/c08627e5b6c6942f432d908ca0f31d6e to your computer and use it in GitHub Desktop.
WordPress :: Divi Builder :: Fullwidth Portfolio Module :: Custom Thumbnail Size
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* DON'T copy the first line (above) if your functions.php already has it. | |
* ---------------------------------------------------------------------- */ | |
function my_et_theme_image_sizes( $sizes ) { | |
$sizes['200x200'] = 'my-et-pb-portfolio-image'; | |
return $sizes; | |
} | |
add_filter( 'et_theme_image_sizes', 'my_et_theme_image_sizes' ); | |
function my_et_fullwidth_portfolio_thumbnail_sizes( $size ) { | |
return 200; | |
} | |
add_action( 'et_pb_portfolio_image_width', 'my_et_fullwidth_portfolio_thumbnail_sizes' ); | |
add_action( 'et_pb_portfolio_image_width', 'my_et_fullwidth_portfolio_thumbnail_sizes' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment