这是我的单条代码。php:
<?php if (have_posts()):the_post() ?>
<h3><?php the_title() ?></h3> <!-- Prints `Hello World` -->
<?php if (!empty($someOtherPosts = get_posts([\'posts_per_page\' => 3]))): ?>
<ul>
<?php foreach ($someOtherPosts as $post): ?>
<li><?php echo $post->post_title ?></li>
<?php endforeach; ?>
</ul>
<?php endif; ?>
<h3><?php the_title() ?></h3> <!-- Prints `Bye World` -->
<?php endif; ?>
为什么在下一次调用中我会得到不同的标题,我该如何处理?