• Resolved KaiSchultka

    (@andrenalin)


    Hey,

    i′am searching how to put my adrotate ads into the ad.
    i found some answers in your forum, but without success

    Adrotate gives you a shortcode [ads_id1] or an function echo adfunctid(1).

    Which way can i go to get an presentably output?

    if there is a way to put the code into a template file i would be happy, i want to use two ads, but i think this does not work because you have an text field in the admin section!?

    is it possible to use adsense code for two positions, e.g. comma separated positions?

    thanks a lot

    https://www.ads-software.com/extend/plugins/another-wordpress-classifieds-plugin/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi andrenalin,

    Well, to add this specific functionality (either as a function or short code), you’d have to hack the plugin under frontend/ad-functions.php, look for the function showad(). That would allow you to call the function you have above. But there’s no way to mod the template, as short code expansion or PHP calls aren’t supported in there.

    Thread Starter KaiSchultka

    (@andrenalin)

    OK, thanks for this information, i was on the right way

    to show my own ads on position 1 and 3 i do this at line 4690

    first i try to put the functions into the layout, but this did not work, you need to put the functions into a variable.
    i comment out the adsense assignment and give the positions my adroutate groups.

    Hope it is useful for some other people!

    $adsensePosition = get_awpcp_option('adsenseposition');
    			$showadsense1=adrotate_group(2);
    			$showadsense2="";
    			$showadsense3=adrotate_group(1);
    			if ($adsensePosition == 1)
    			{
    				//$showadsense1="$showadsense";
    			}
    			else if ($adsensePosition == 2)
    			{
    				//$showadsense2="$showadsense";
    			}
    			else if ($adsensePosition == 3)
    			{
    				//$showadsense3="$showadsense";
    			}
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘alternative to adsense code, multiple ads’ is closed to new replies.