wordpress帖子缩略图大小调整问题

wordpress帖子缩略图大小调整问题,wordpress,post,slider,thumbnails,Wordpress,Post,Slider,Thumbnails,我试图在自定义帖子循环中调整帖子缩略图图像的大小,但采用的是原始图像的大小 <div id="main-slider" class="flexslider"> <ul class="slides"> <?php $loop = new WP_Query(array('post_type' => 'sliders', 'orderby' => 'post_i

我试图在自定义帖子循环中调整帖子缩略图图像的大小,但采用的是原始图像的大小

             <div id="main-slider" class="flexslider">
              <ul class="slides"> 


                    <?php $loop = new WP_Query(array('post_type' => 'sliders', 'orderby' => 'post_id', 'order' => 'ASC')); ?>
              <?php while($loop->have_posts()): $loop->the_post(); ?>
                    <li>
                    <?php the_post_thumbnail('homepage-thumb'); ?>
                    <div class="flex-caption">
                        <h3><?php the_title(); ?></h3> 
                        <p><?php the_excerpt(); ?></p> 
                        <a href="#" class="btn btn-theme">Learn More</a>
                    </div>

                  </li>
                 <?php endwhile; ?>
               </ul>
            </div>
<!-- end slider -->
        </div>`
`

             <div id="main-slider" class="flexslider">
              <ul class="slides"> 


                    <?php $loop = new WP_Query(array('post_type' => 'sliders', 'orderby' => 'post_id', 'order' => 'ASC')); ?>
              <?php while($loop->have_posts()): $loop->the_post(); ?>
                    <li>
                    <?php the_post_thumbnail('homepage-thumb'); ?>
                    <div class="flex-caption">
                        <h3><?php the_title(); ?></h3> 
                        <p><?php the_excerpt(); ?></p> 
                        <a href="#" class="btn btn-theme">Learn More</a>
                    </div>

                  </li>
                 <?php endwhile; ?>
               </ul>
            </div>
<!-- end slider -->
        </div>`
它不显示图像的硬裁剪大小

             <div id="main-slider" class="flexslider">
              <ul class="slides"> 


                    <?php $loop = new WP_Query(array('post_type' => 'sliders', 'orderby' => 'post_id', 'order' => 'ASC')); ?>
              <?php while($loop->have_posts()): $loop->the_post(); ?>
                    <li>
                    <?php the_post_thumbnail('homepage-thumb'); ?>
                    <div class="flex-caption">
                        <h3><?php the_title(); ?></h3> 
                        <p><?php the_excerpt(); ?></p> 
                        <a href="#" class="btn btn-theme">Learn More</a>
                    </div>

                  </li>
                 <?php endwhile; ?>
               </ul>
            </div>
<!-- end slider -->
        </div>`

请帮我解决这个问题。提前感谢

上传图像后,您是否进行了自定义裁剪?如果是这样,您将需要重新生成图像。是的,我重新上载了新图像,但未工作。它显示幻灯片图像的原始大小。这可能是css的问题,但我无法识别错误。嘿,伙计!!现在它开始工作了。我刚刚重新上传了另一张新图片,它需要进行硬裁剪。谢谢你的建议。
             <div id="main-slider" class="flexslider">
              <ul class="slides"> 


                    <?php $loop = new WP_Query(array('post_type' => 'sliders', 'orderby' => 'post_id', 'order' => 'ASC')); ?>
              <?php while($loop->have_posts()): $loop->the_post(); ?>
                    <li>
                    <?php the_post_thumbnail('homepage-thumb'); ?>
                    <div class="flex-caption">
                        <h3><?php the_title(); ?></h3> 
                        <p><?php the_excerpt(); ?></p> 
                        <a href="#" class="btn btn-theme">Learn More</a>
                    </div>

                  </li>
                 <?php endwhile; ?>
               </ul>
            </div>
<!-- end slider -->
        </div>`