Re: weeks revisited

From: Date: Mon, 19 Mar 2001 22:55:38 +0000
Subject: Re: weeks revisited
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-44633@lists.php.net to get a copy of this message
OK I did this below and it works just great. I had stumbled across the message earlier. my next question would be. I'm working on a list of meetings. I return a list for the current month, what I would like to do is make the current week meetings show in red. However, I'm not sure of the best approach to do this. do I look at each date with a function of my own? or is there a php function I can use that I'm not aware of? thanks for any and all help chris >for MySQL add a WHERE (WEEK(yourtimefield) = WEEK(NOW())) > >this will have the problem that it will show all of week X even if you're >on 23:55 on the last day of that week > >WHERE ((yourtimefield >= NOW()) AND (yourtimefield <= DATE_ADD(NOW(), >INTERVAL 1 WEEK)) > >might be better > >-- >Christian Reiniger >LGDC Webmaster (http://sunsite.dk/lgdc/) > >...10001000110101011010101101011110111010113...???? > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net >For additional commands, e-mail: php-general-help@lists.php.net >To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#44633) next »