Jump to content

rb415

New Members
  • Content count

    1
  • Joined

  • Last visited

Community Reputation

0 Neutral

About rb415

  • Rank
    Newbie
  1. Hi everyone, I am having an issue with getting these posts to cycle through randomly each time the page is visited. I have some code that shows everything that I need to be seen but for some reason it only shows the 1st post. It never cycles any of the information. Any help with this would be greatly appreciated. Here is what my code looks like. <div class="partner-box-2"> <?php query_posts('post_type=portfolio&showposts=1&offset=0&orderby=rand'); ?> <?php if (have_posts()) : while (have_posts()) : the_post(); ?> <h3>Partners</h3> <h4><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h4> <img style="padding-top:10px;" src="<?php the_field('company_productimage'); ?>" /> <div style="padding-top:10px;padding-bottom:10px;font-size:85%;line-height:120%;"> <?php the_field('company_summary'); ?> </div> <div align="center" class="smaller-button"><a style="color:#fff;text-decoration:none;" href="<?php the_permalink(); ?>" >More About <?php the_field('company_short_name'); ?></a></div> <?php endwhile; endif; ?> <?php wp_reset_query(); ?> </div>
×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.