Hi!Chuckun wrote:My question is as the title suggests.. Can I specify which adverts to show depending on what category the forum belongs to in the board directory?
Example: If a users forum is registered under a 'Technology' category, can I define an ad code specifically for the Technology category?
If so, would it be as simple as adding something like the following in the advert area (I believe you can use PHP there?):
Thanks for your time,Code: Select all
<? if($category_id == "5") { include("../ads/tech_ads.php"); } else { include("../ads/main_ads.php"); } ?>
Chuckun
You can follow these steps:
- 1. Log into Admin Area PHP Multiforums.
2. Look in System->Configuration->Hosted forums->Security Options->click select 'Yes' to Execute PHP Code in Ads.
3. Look in Ads->Manages Ads->in "Is this PHP Code?" option->click select 'Yes'. Now, you can use php code in Ads.Code: Select all
if ($echophp->forum['cat'] == '1') { include('put file path here'); } else { include('put file path here'); }
Thank you.