Coinbase

Author Topic: Time display Ad  (Read 3086 times)

0 Members and 1 Guest are viewing this topic.

Offline lukasino

  • Newbie
  • *
  • Posts: 1
    • Email
Time display Ad
« 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

Offline ccbtimewiz

  • Sr. Member
  • ****
  • Posts: 326
    • Dream Portal
Re: Time display Ad
« Reply #1 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

SMF Ads Support Forum

Re: Time display Ad
« Reply #1 on: December 11, 2008, 04:21:05 pm »
.