WordPress.org

Ready to get started?Download WordPress

Forums

Inserting banner after 2nd & 3rd post (2 posts)

  1. craven222
    Member
    Posted 1 year ago #

    I'm struggling to find any clear guide on doing this, I've slightly adjusted this code

    http://www.ilovecolors.com.ar/ads-wordpress-loop/

    to try and get what I'm looking for, but inserting that code causing my web page to time out.

    Here's my loop.php

    http://pastebin.com/S9uGRtCC

    Ta

  2. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

    try and move the $count++; to before the endif; -

    i.e. change these sections:

    <?php if ($count == 1) : ?>
    <?php echo adrotate_ad( ??? ); ?>
    <?php endif; $count++; ?>

    to:

    <?php if ($count == 1) : ?>
    <?php echo adrotate_ad( ??? ); ?>
    <?php $count++; endif; ?>

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.