我在我的 wordpress 主题中创建了一个自定义页面。该页面工作正常。但是我在使用 the_content(); 时遇到了麻烦。功能。我正在使用一些自定义字段在页面上显示一些内容,并且我希望在编辑器中输入的页面内容显示在页面上的特定位置。但是,无论我在编辑器中输入什么,都会被放置在页面顶部的所有其他内容之上。
编辑:
这是完整的代码:
<?php get_header(); ?>
<div id="main-content">
<?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>
<?php the_content(); ?>
<?php endwhile; ?>
<?php endif; ?>
<div class="mobile-top">
<a href="<?php the_permalink(); ?>">
<p><?php the_title(); ?> price</p>
</a>
</div>
<?php comments_template(); ?>
</div>
</div> <!--main-content Ends-->