WordPress.org

Ready to get started?Download WordPress

Forums

WP125
WP125 clone (5 posts)

  1. alabasta79
    Member
    Posted 2 years ago #

    Hi...
    Thanks for this is very amazing plugin. But i need to show two different wp125. One in the top (horizontal) and one on the sidebar. So I need two different wp125 plugin. I cannot use the same because if i put one on top and one on my sidebar, the same ads will be shown...

    Any idea? Thanks

    http://wordpress.org/extend/plugins/wp125/

  2. Dave R
    Member
    Posted 1 year ago #

    I want to show two different ads on the page. One in left column and a different one in the right column.

  3. naspiegel
    Member
    Posted 1 year ago #

    Yes, It would be great to be able to have 2 (or 3) panels of this ad plugin on a site. The plugin was written for 1, however you can use the wp125_single_ad() function to allow for multiple uses. Here's a function I wrote that works for a single vertical line of ads that can be used multiple times. (This was written for one row several columns, you would have to adjust it for one column several rows...)
    You call the function called adline(). It calls for 2 parameters, the 1st slot number through..., the last slot number in wp125 you want to use for that row of ads. I use six across so I use 1,6 as the default values. Here is what the a sample code line would look like adline(1,6);

    here is the function (add this to your functions.php file)

    function adline($adarg1 = 1, $adarg2 = 6){
    echo '<table border="0" cellspacing="3" cellpadding="0" width="100%" align="center">';
    echo '<tbody><tr>';
    for ($i=$adarg1; $i<=$adarg2; $i++)
      {
        echo '<td>';
        wp125_single_ad($i);
        echo '</td>';
    }
        echo '</tr></tbody></table>';
    }

    Cheers!

  4. Green machine
    Member
    Posted 1 year ago #

    Hy naspiegel,

    Thanx for the code. I think a lot of people are looking for a solution to this problem. My question is in which file does this code go?

    Thanx for the reply!

  5. naspiegel
    Member
    Posted 1 year ago #

    I believe I wrote...

    Add this to your functions.php file in your theme directory.

    of course the adline function you put, wherever you want the ads to appear.

    Cheers!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic