Reputation: 597
this is a wordpress problem. I know I can add a class to a wordpress featured image via this:
<?php the_post_thumbnail('post-thumbnail', ['class' => 'img-responsive']); ?>
However how do I add multiple? I tried using an array but it just displays array in inspecter and I am not sure if it worked. Please help. Thanks.
Upvotes: 3
Views: 2312
Reputation: 1783
You could try it simply like this:
<?php the_post_thumbnail('post-thumbnail', ['class' => 'img-responsive my-other-class']); ?>
Upvotes: 6