【发布时间】:2020-07-10 09:46:56
【问题描述】:
我是 Understrap 的新手,我想在显示所有帖子的博客页面上添加一些 margin-top。与我使用的其他空白 wordpress 主题启动器不同,我还不知道将页边距添加到帖子页面的结构。在content.php single.php 和content-single 之间,我有点迷茫。如果有人可以指导我,我将非常感激。
【问题讨论】:
标签: php wordpress bootstrap-4
我是 Understrap 的新手,我想在显示所有帖子的博客页面上添加一些 margin-top。与我使用的其他空白 wordpress 主题启动器不同,我还不知道将页边距添加到帖子页面的结构。在content.php single.php 和content-single 之间,我有点迷茫。如果有人可以指导我,我将非常感激。
【问题讨论】:
标签: php wordpress bootstrap-4
我发现我不得不修改 index.php 页面。 我还想在我的 Resent 帖子页面中添加一个标题,所以我修改了索引 php:
<div class="wrapper" id="index-wrapper">
<div class="darkness"></div>
<div class="<?php echo esc_attr( $container ); ?>" id="content" tabindex="-1">
<div class="row">
<!-- Do the left sidebar check and opens the primary div -->
<?php get_template_part( 'global-templates/left-sidebar-check' ); ?>
<main class="site-main" id="main">
<h1 class="mb-3">Recent Posts</h1>
<?php if ( have_posts() ) : ?>
<?php /* Start the Loop */ ?>
<?php while ( have_posts() ) : the_post(); ?>
类 dark 的 div 是在页面顶部添加一些额外的边距和颜色,以放在透明标题的后面。最后,这就是我所需要的。
【讨论】: