Quantcast
Channel: responsive – WordPress.org Forums
Viewing all articles
Browse latest Browse all 16569

Kinoko_Tamashi on "Content Responsive Images"

$
0
0

I am trying to get my page's images to scale with the slider container they're inside of. We're using the hotec theme with royal sliders and I added a filter to the functions.php file in hopes that this would bring me content responsive images.

<?php
add_filter( 'post_thumbnail_html', 'remove_thumbnail_dimensions', 10 );
add_filter( 'image_send_to_editor', 'remove_thumbnail_dimensions', 10 );
function remove_thumbnail_dimensions( $html ) {
$html = preg_replace( '/(width|height)=\"\d*\"\s/', "", $html );
return $html; }
?>

Do I need to change anything after this to get the images to respond?


Viewing all articles
Browse latest Browse all 16569

Latest Images

Trending Articles



Latest Images