I want to show two different ads on the page. One in left column and a different one in the right column.
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!
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!
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!