fixes for marketing

This commit is contained in:
Jerry
2020-09-02 12:56:53 +03:00
parent 3a4080c4c9
commit 9462e0af00
4 changed files with 18 additions and 7 deletions

View File

@@ -238,5 +238,13 @@ function get_lawcarta_ga_config(){
return $res;
}
add_filter( 'post_thumbnail_html', 'remove_width_attribute', 10 );
add_filter( 'image_send_to_editor', 'remove_width_attribute', 10 );
function remove_width_attribute( $html ) {
$html = preg_replace( '/(width|height)="\d*"\s/', "", $html );
return $html;
}