• I have a website which uses some standard HTML5 pages and then WordPress for the blog/news part. I have done this a few times in the past to suit my needs and it has always worked out well.

    I want to send my top news story to publish on one of my standard HTML5 pages. I know how to do this `(<?php
    require(‘media/wp-blog-header.php’);
    ?>` in the header etc.) but am having an issue with the size of the thumbnail which displays.

    I am using this code for the thumbnail on my page:

    <?php if ( has_post_thumbnail() ) {
      the_post_thumbnail();
    }
    ?>

    The problem I have is that the image is set to 760px x 360px on WordPress. I need it that way but on my HTML5 page I need the image to display at 311px x 147px to fit i with my design.

    Is there a way I can edit the above PHP code to make the image display at my required size?

    Thanks in advance

    (PS .. If anyone can tell me the code to index 3 more posts under my main post – that would be amazing!)

  • The topic ‘g WThumbnail size when displayinordpress post on HTML website page’ is closed to new replies.