SimplePortal

Customization => Custom Coding => Topic started by: waruna on February 28, 2010, 01:00:38 AM

Title: Need help to put advertisement
Post by: waruna on February 28, 2010, 01:00:38 AM
Hello guys, 2 quick question:

1) Can someone help me how to put an ads at portal index?  I tried to add a top/bottom html block, but the ads is 700px width, so the block appears to have a scrollbar navigation and that is not nice to see. How can I remove the scrollbar? :'(

2) How to put google ads in correct way? Because seems to me the ads doesn't appear at all. I tried to insert the script inside <body> </body> tag also can't help. I tested the script using manual html/php file and the ads perfectly works.  Am I done something wrong?

Thanks in advance.
Title: Re: Need help to put advertisement
Post by: waruna on March 02, 2010, 02:33:09 PM
Anyone? :(
Title: Re: Need help to put advertisement
Post by: Old Fossil on March 18, 2010, 10:15:45 PM
Regarding

1. Is the advert a banner? if so could you resize it?

2. Are the permissions set so adverts can be seen?
Title: Re: Need help to put advertisement
Post by: escorta.biz on March 19, 2010, 06:12:42 AM
You may use the Ad management mod (http://custom.simplemachines.org/mods/index.php?mod=255) and edit the portal index where you can ad the proper code.

For instance, after installing "Ad management mod", if you would like to add an ad right below the menu, you should ad the following code:
Code: [Select]
//Below the menu ads
if (function_exists("show_indexAds"))
{
$ads = show_indexAds();
if(!empty($ads))
if($ads['type']==0)
echo $ads['content'];
else
eval($ads['content']);
unset($ads);
}



echo '
<br class="clear" />';

Unfortunately i don't know which file you should edit and where you should put the above code; maybe someone will guide us, because i'm having the same issue.
Title: Re: Need help to put advertisement
Post by: [SiNaN] on March 20, 2010, 10:54:12 AM
It should go into the Portal.template.php file. If you want it at the top, in template_portal_above() or if you want it at the bottom, in template_portal_below() function.
SimplePortal 2.3.8 © 2008-2024, SimplePortal