I am trying to convert my HTML page to a WordPress Theme and so far i am not doing too bad! but I have a problem on loading a Custom post Type thumbnail and adding the required class and style to it. In my HTML I have an image tag like this:
<img class="img-circle" src="img/welcom.jpg" data-src="holder.js/140x140" alt="140x140" style="width: 140px; height: 140px;">
I trird to echo above tag in my custom WP Query by contaminating the src attribute like src="'.the_post_thumbnail().'"
as:
echo ' <img class="img-circle" src="'.the_post_thumbnail().'" alt="140x140" style="width: 140px; height: 140px;">';
Now I am getting the image on the page but it is not getting any classes and style and the source code looks like Can you please let me know how to fix this?