Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想在我的帖子页面中使用特色图片,问题是,我没有看到这个。我怎样才能做到这一点?
我以为我必须在 functions.php 中编写此代码,并且已解决 add_theme_support('post_thumbnails');
但不幸的是。谁能帮我解决这个问题?
此功能对于将特色图像放入帖子页面很有用。您可以将其添加到您的循环中,也可以将 $post_id、$size、$attr 传递给该函数。
<?php the_post_thumbnail(); ?>