Support » Fixing WordPress » How To Make Category Like This ???

  • v123shine

    (@v123shine)


    I want to make category like this => view image http://i.imgur.com/JZg47.jpg

    Note:
    I want make a category with first post have “images, title and short description”. others 3 post (2,3,4 post) only have “title”

    Can someone help me, please!

    Thank you

Viewing 8 replies - 1 through 8 (of 8 total)
  • JungleSpace.net

    (@junglespace)

    Here’s a documentation to tell you more about how post are displayed in a list.

    http://codex.wordpress.org/The_Loop

    Different themes have different approaches but the every theme should follow the same basic concept.

    v123shine

    (@v123shine)

    Thank you so much JungleSpace.net for help me.

    Can you give to me the php code to display the first post with image and short description and other post only title, please!

    JungleSpace.net

    (@junglespace)

    Unfortunately, if you’re looking for a full code customization, the better site to seek help is on the Job Board.

    http://jobs.wordpress.net/

    Michael

    (@alchymyth)

    Forum Moderator

    what is the current code of your category archive template?

    where is the image coming from? are you using the ‘featured image’ for this, or just the first image from the post?

    please post a link to your site to illustrate what you have so far.

    some links:

    http://codex.wordpress.org/Function_Reference/the_post_thumbnail
    http://codex.wordpress.org/Function_Reference/the_excerpt
    http://codex.wordpress.org/Function_Reference/the_title

    v123shine

    (@v123shine)

    Thank you so much Alchymyth for help me.

    This is my site url: http://linkopen.net/3njy

    I create manual the template.

    This is the code of my category

    <!--Bola-->
    <div class="ks_category_left">
    <h1 class="ks_h1_title_item1">Bola</h1>
    <?php $recent = new WP_Query("cat=4&showposts=3"); while($recent->have_posts()) : $recent->the_post();?>
    <div class="ks_posts_item1">
    <div class="ks_postimage">
    <a href="<?php the_permalink() ?>" title="<?php the_title_attribute(); ?>">
    <?php get_the_image( array( 'size' => 'thumbnail', 'default_image' => 'http://kabarsore.com/noimages.jpg') ); ?>
    </a>
    </div>
    <div class="ks_title_desc">
    <div class="ks_postinfo">
    <a href="<?php the_permalink() ?>" title="<?php the_title_attribute(); ?>">
    <h4><?php $tit = the_title('','',FALSE); echo substr($tit, 0, 60); if (strlen($tit) > 60) echo " ..."; ?></h4>
    </a>
    </div>
    <div class="ks_desc">
    <?php echo get_excerpt(145); ?>
    </div>
    </div>
    </div>
    <?php endwhile; ?>
    </div>
    <!--end Bola-->

    # where is the image coming from? are you using the ‘featured image’ for this, or just the first image from the post?

    Image come from first thumb image on post and i using plugin “Get the Image” to display the image.

    Please help me.

    Michael

    (@alchymyth)

    Forum Moderator

    a general idea; might need a lot of formatting:

    http://pastebin.com/CSN7KhR0

    v123shine

    (@v123shine)

    Great idea, you solve my problem 🙂

    Others question, i think i need using the ‘featured image’ for first post, can you give to me the full code please!

    Thank you so much Alchymyth for help me 🙂

    Michael

    (@alchymyth)

    Forum Moderator

    try to replace the ‘get_the_image()’ line with ‘the_post_thumbnail()’

    http://codex.wordpress.org/Function_Reference/the_post_thumbnail

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘How To Make Category Like This ???’ is closed to new replies.