note 21421 added to ref.mcal
| From: | verdy_p at wanadoo dot fr | Date: | Sun, 12 May 2002 15:55:48 +0000 |
| Subject: | note 21421 added to ref.mcal | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-30546@lists.php.net to get a copy of this message | ||
Correction to previous extensive note:
ANDing distinct bit values will always result in zero, so your weekly events won't ever be
raised. You must use the bitwise-or operator (|) to combine several week days.
mcal_event_set_recur_weekly takes an additional integer parameter
"weekdays" which is basicly a binary mask created by bitwise
ORing together integers representing the days of the week.
Sunday = 1
Monday = 2
Tuesday = 4
Wednesday = 8
Thursday = 16
Friday = 32
Saturday = 64
So if I wanted the value needed to raise the event every "Monday, Wednesday, and Friday" I
would do this:
$weekdays = 2 | 8 | 32;
--
http://www.php.net/manual/en/ref.mcal.php
http://master.php.net/manage/user-notes.php?action=edit+21421
http://master.php.net/manage/user-notes.php?action=delete+21421
http://master.php.net/manage/user-notes.php?action=reject+21421