• Hi Guys,
    Please i need your assistance on this php code on wordpress.

    What i really want to achieve is a loop of posts (all categories), and i want it to show the category name on each post. i want the category name to be positioned on top of the thumbnail. like the way it is on this site www dot naijaonpoint dot com

    here is my own site link test dot xwaizi dot com

    Thanks in anticipation.

    <?php

    /*

    Template Name: New Home Templates

    */

    ?>
    <?php get_header(); ?>

    <div class=”col-md-12 latestinfo”>
    <h4 class=”widgettitle”>
    THE LATEST
    </h4>

    <?php $args = array(
    ‘post_limit’ => ”,
    ‘post_random’ => ‘yes’,
    ‘category_include’ => ‘,’,
    ‘cat_name’ => yes,
    ‘display_thumbnail’ => yes,
    ‘thumbnail_height’ => 188,
    ‘thumbnail_link’ => yes,
    ‘thumbnail_width’ => 272,
    ‘post_content_length’ => 30,
    ‘post_content_length_mode’ => words,
    ‘post_random’ => yes,
    ‘post_title_length’ => 50,
    ‘post_title_length_mode’ => words,
    ‘post_date’ => yes,
    ‘widget_title’ => ”,
    ‘string_break’ => ”
    );

    if( function_exists( ‘special_recent_posts’ ) ) {
    special_recent_posts( $args );
    }
    ?>
    </div>

    <?php get_footer(); ?>

  • The topic ‘[ Post Loop ] Please i need somebody to help me look at this php code.’ is closed to new replies.