Last active
June 30, 2018 07:20
-
-
Save SteveRyan-ASU/e129e2f68e1867875a0c23597ac85a06 to your computer and use it in GitHub Desktop.
Recommended patch from ET to produce square featured images for blog module posts.
This file contains 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 | |
/** | |
* Plugin Name: ASU Divi - ET Patch, Square Featured Images for Blog Module | |
* Plugin URI: https://gist.github.com/SteveRyan-ASU/e129e2f68e1867875a0c23597ac85a06/edit | |
* Description: Recommended patch from ET to produce square featured images for blog module posts. | |
* Author: Steve Ryan, ASU Engineering | |
* Author URI: https://engineering.asu.edu | |
* Version: 0.1 | |
* | |
*/ | |
// Recommended patch from ET to produce square featured images for blog module posts. | |
add_filter( 'et_pb_blog_image_width', 'custom_image_width' ); | |
function custom_image_width($width) { | |
return '400'; | |
} | |
add_filter( 'et_pb_blog_image_height', 'custom_image_height' ); | |
function custom_image_height($height) { | |
return '400'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment