Holiday Logo Rotator

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   Holiday Logo Rotator
dsnail2000
CZ Super Newbie
 Codezwiz Site Donator
dsnail2000 has been a member for over 20 year's 20 Year Member
usa.gif virginia.gif
Age: 41
Gender: Male
Website:
Status: Offline
Joined: Jun 28, 2004
0.00 posts per day
Posts: 36
Points: 6,786
   
Arg.. I can't find an easy way to rotate my logo on specific days (or a range of days) each year. Inspired by google, I have a bunch of holiday and special events logo's for my site. I want to be able to upload the logo's and use a script to specify when it should be shown in place of the regular logo. Anybody know of a php script that I could use or modify to use with php-nuke?



Back to top Reply with quote
#2   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,475
   
Sounds like you want to make a database table that stores the images then make yourself up a script to select the one you want on that day and show it.




_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
#3   
dsnail2000
CZ Super Newbie
 Codezwiz Site Donator
dsnail2000 has been a member for over 20 year's 20 Year Member
usa.gif virginia.gif
Age: 41
Gender: Male
Website:
Status: Offline
Joined: Jun 28, 2004
0.00 posts per day
Posts: 36
Points: 6,786
   
Yeah, and the script basically runs an if statement.

$logo_url = " ( url of the logo of your site) "
$holiday => (value for today's date, don't know how to write that code off the top of my head

IF ($holiday != NULL){
$logo_url => $holiday;
}


The hardest part (for me at least)would be to create a simple admin panel that would allow me to easily add the url's to the database.


Back to top Reply with quote
#4   re: Holiday Logo Rotator
dsnail2000
CZ Super Newbie
 Codezwiz Site Donator
dsnail2000 has been a member for over 20 year's 20 Year Member
usa.gif virginia.gif
Age: 41
Gender: Male
Website:
Status: Offline
Joined: Jun 28, 2004
0.00 posts per day
Posts: 36
Points: 6,786
   
I went ahead and wrote out exactly what I want it to do.

Mission: To change a logo/image for specific holiday's or special events.

Requirements:
  1. To only have the code execute once a day, not every time the logo is required.
  2. To be able to change the logo/image on a specific date, a range of dates, a specific day (ex: first monday of March) and for only that day or x number of days after that.
  3. Built an admin interface for nuke, and one for any PHP/MySQL/cron enabled site.
  4. If no special image is defined, use a default image, defined by the admin interface.

Wishlist:
  • Be able to handle more than one logo rotation. <- Updated
  • Be able to upload the image from the admin interface.
  • Be able to provide a title for the image to use for the alt tag.
  • have it automatically detect the image dimesions.



Back to top Reply with quote
#5   
dsnail2000
CZ Super Newbie
 Codezwiz Site Donator
dsnail2000 has been a member for over 20 year's 20 Year Member
usa.gif virginia.gif
Age: 41
Gender: Male
Website:
Status: Offline
Joined: Jun 28, 2004
0.00 posts per day
Posts: 36
Points: 6,786
   
I updated the wishlist to include the ability to have it rotate more than one set of images.. that's really the only way it will be worth all the trouble to create it. I also posted this on the phpbb website [ Register or login to view links on this board.] .



Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

Jump to 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum