Thread: Php question
View Single Post
Old 03-02-2010, 07:30 PM  
sarettah
see you later, I'm gone
 
Industry Role:
Join Date: Oct 2002
Posts: 14,060
Quote:
Originally Posted by teh ghey View Post
I have this If statement
<!-- IF active_module == "homepage" -->
show image here
<!-- ENDIF -->
I only want to use this IF statement on monday - thursday.

on friday-sunday I do not want to use the IF statement, so it just shows the image on every page, not just the homepage.

How can I make it so that the IF statement only runs monday through thursday, and on friday-sunday it doesnt use the IF?
if date('w',time())>=1 && date('w',time())<=4 && .................

That will check if the day of the week is between Monday (1) and Thursday (4)
__________________
All cookies cleared!

Last edited by sarettah; 03-02-2010 at 07:32 PM..
sarettah is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote