Show widget differently depending on if it’s in the sidebar or footer

I’ve made a custom widget which shows thumbs of my latest videos. These thumbs are set to be 300px wide, which is the same width of my sidebar.

My problem is that i also want to be able to use it in my footer where the width of widgets are only 220px wide.

Read More

So basically what i want to do is: if the widget is shown in the sidebar use <?php the_post_thumbnail('media-thumb-sidebar'); ?>and if the widget is used in the footer use <?php the_post_thumbnail('media-thumb-footer'); ?>

Anyone know how i could do this? Thanks 🙂

Related posts

Leave a Reply

1 comment