Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/36.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/297.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 3列布局wordpress(一页3篇文章)_Php_Css_Html_Wordpress_Multiple Columns - Fatal编程技术网

Php 3列布局wordpress(一页3篇文章)

Php 3列布局wordpress(一页3篇文章),php,css,html,wordpress,multiple-columns,Php,Css,Html,Wordpress,Multiple Columns,我的客户希望他的新闻页面上有3个专栏和3篇文章 每列都有标题名、日期、摘录和阅读更多功能 像这样: 因为我的PHP知识不是很好,我正在寻找一些教程来创建3列页面。但是所有这些教程都过时了,缺乏信息,或者它们似乎没有那么好用 “留下回复”可以移动到single.php 所以我希望你们中的一些人能给我一些帮助 这是我当前的content.php <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>

我的客户希望他的新闻页面上有3个专栏和3篇文章

每列都有标题名、日期、摘录和阅读更多功能

像这样:

因为我的PHP知识不是很好,我正在寻找一些教程来创建3列页面。但是所有这些教程都过时了,缺乏信息,或者它们似乎没有那么好用

“留下回复”可以移动到single.php

所以我希望你们中的一些人能给我一些帮助

这是我当前的content.php

<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
        <div class="aside">
            <h1 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php echo esc_attr( sprintf( __( 'Permalink to %s', 'twentytwelve' ), the_title_attribute( 'echo=0' ) ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h1>
            <div class="entry-content">
                <?php the_content( __( 'Continue reading <span class="meta-nav">&rarr;</span>', 'twentytwelve' ) ); ?>
            </div><!-- .entry-content -->
        </div><!-- .aside -->

        <footer class="entry-meta">
            <a href="<?php the_permalink(); ?>" title="<?php echo esc_attr( sprintf( __( 'Permalink to %s', 'twentytwelve' ), the_title_attribute( 'echo=0' ) ) ); ?>" rel="bookmark"><?php echo get_the_date(); ?></a>
            <?php if ( comments_open() ) : ?>
            <div class="comments-link">
                <?php comments_popup_link( '<span class="leave-reply">' . __( 'Leave a reply', 'twentytwelve' ) . '</span>', __( '1 Reply', 'twentytwelve' ), __( '% Replies', 'twentytwelve' ) ); ?>
            </div><!-- .comments-link -->
            <?php endif; // comments_open() ?>
            <?php edit_post_link( __( 'Edit', 'twentytwelve' ), '<span class="edit-link">', '</span>' ); ?>
        </footer><!-- .entry-meta -->
    </article><!-- #post -->

设置wordpress



你的CSS看起来像什么?你只是在问如何像链接到的图像一样设置页面的样式吗?设置页面的样式似乎并不难。我要找的是创建布局所需的php脚本(在functions.php中),因此每次添加新帖子时,只有布局在更新内容。具有多页检查的可能性。
<?php if ( have_posts() ) :  while ( have_posts() ) : the_post();?>
<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
        <div class="aside">
            <h1 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php echo esc_attr( sprintf( __( 'Permalink to %s', 'twentytwelve' ), the_title_attribute( 'echo=0' ) ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h1>
            <div class="entry-content">
                <?php the_content( __( 'Continue reading <span class="meta-nav">&rarr;</span>', 'twentytwelve' ) ); ?>
            </div><!-- .entry-content -->
        </div><!-- .aside -->
            <?php edit_post_link( __( 'Edit', 'twentytwelve' ), '<span class="edit-link">', '</span>' ); ?>
    </article><!-- #post -->
<?php endwhile; endif; wp_reset_query(); ?>