diff options
Diffstat (limited to 'content-page.php')
-rw-r--r-- | content-page.php | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/content-page.php b/content-page.php new file mode 100644 index 0000000..dceb945 --- /dev/null +++ b/content-page.php @@ -0,0 +1,52 @@ +<?php +printf ( '<section class="main col-md-8"> + <h6 class="page-libre">no_title</h6> + <div class="row posts">'); + //Lógica de the_loop + //Si (hay entradas) + //mientras (hay entradas) + //muestra la info de las entradas + //Si no + //no hay entradas publicadas + if( have_posts() ): + while( have_posts() ): + the_post(); + //echo ''; + $template_html = ' + <article class="col-sm-12 post"> + <div class="contenedor"> + <div class="thumb"> + %s + </div> + <div class="info"> + <h2 class="titulo">%s</h2> + <p class="fecha">%s</p> + <div class="categorias"> + %s + </div> + '; + printf( + $template_html, + get_the_post_thumbnail(), + get_the_title(), + get_the_time( 'd-M-Y' ), + get_the_category_list() + //get_the_content() + //the_category() + ); + printf(' <div class="texto"> + <div>'); + the_content(); + printf(' </div> + </div> + </div> + </div> + </article>' + ); + endwhile; + else: + printf( '<p>' . __('No hay entradas', 'libre') . '</p>' ); + endif; + rewind_posts(); +printf(' </div> + </section>'); |