SMF Ads Support Forum

Support => Feedback/Request => Topic started by: lukasino on December 11, 2008, 05:30:48 am

Title: Time display Ad
Post by: lukasino on December 11, 2008, 05:30:48 am
Hello,

It's possible to ad time to display Ad.

example

i have two Ad.

1. Ad1  (Display ads on board index) 0:00-15:59
2. Ad2  (Display ads on board index) 16:00-23:00
Title: Re: Time display Ad
Post by: ccbtimewiz on December 11, 2008, 04:21:05 pm
Yes, somewhat.

Open index.template.php, and do something in similar terms to:

$forum_hour = date('H', forum_time());

if( $forum_hour < 16 )
    // ad code for ads to show up between the hours of 12am through 4pm

elseif( $forum_hour < 24 )
    // ad code for ads to show up between the hours of 4pm through 11:59pm