Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Blocks
Author Message
alexwise
Regular
Regular


Joined: Oct 15, 2005
Posts: 80

PostPosted: Sat May 06, 2006 7:35 pm Reply with quote

Does anyone know were I can get a image of the day block that isnt radnom, so I can display a specific image acording to what day it is.
Also I don't need any voting system for it.

Thanks Very Happy
 
View user's profile Send private message
alexwise
PostPosted: Mon May 08, 2006 11:43 am Reply with quote

Nothing? Confused
 
montego
Site Admin


Joined: Aug 29, 2004
Posts: 9449
Location: Arizona

PostPosted: Tue May 09, 2006 5:53 am Reply with quote

Are you using anything to manage the images, such as Gallery? These usually come with blocks like this, however, I am not sure about the "voting system" thing. It may be there in Gallery...

_________________
Only registered users can see links on this board! Get registered or login!
Only registered users can see links on this board! Get registered or login! 
View user's profile Send private message Visit poster's website
alexwise
PostPosted: Wed May 10, 2006 8:42 am Reply with quote

No we don't have or need a Gallery, bascily all we need is a block that will display a image for each day of the week.
So Monday will have its own image Tuesday will have it's etc etc.

It's for a radio station, and the idea is it will show who is on today but with the aid of a image so we can make it look all jazzed up rather than just some text.

That's all we need but from searching all that seems to be out there is Random blocks that has built in Gallery, voting for pic's etc ... that too much we just need a simple block that will disply a specfic image for what day it is.
 
guidyy
Worker
Worker


Joined: Nov 22, 2004
Posts: 208
Location: Italy

PostPosted: Wed May 10, 2006 9:34 am Reply with quote

This is how a php dumb would make it...

Code:


<?
$today=date("D");

if ($today=="Mon")
{
echo "Image for Monday";
}
else if ($today=="Tue")
{
echo "image for Tuesday";
}
else if ($today=="Wed")
{
echo "image for wednesday";
}
else if ($today=="Thu")
{
echo "image for Thursday";
}
else if ($today=="Fri")
{
echo "image for Friday";
}
else if ($today=="Sat")
{
echo "image for Saturday";
}
else if ($today=="Sun")
{
echo "image for Sunday";
}
?>


Replace "image for xxx" with your image path

Guido
 
View user's profile Send private message Visit poster's website MSN Messenger
alexwise
PostPosted: Thu May 11, 2006 8:03 am Reply with quote

Thank you guidyy Very Happy

I converted the code into a block and it seems to be working fine, il just have to wait till the server changes day so I can see if it will display the next day ok.

Thanks.


Last edited by alexwise on Thu May 11, 2006 6:03 pm; edited 1 time in total 
guidyy
PostPosted: Thu May 11, 2006 10:24 am Reply with quote

let me know if it worked..
I might promote myself to chief php dumb ROTFL speedtype
 
alexwise
PostPosted: Thu May 11, 2006 6:04 pm Reply with quote

Yup Works great in a block thanks Very Happy
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Blocks

View next topic
View previous topic
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 can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©