Welcome Guest, Not a member yet? Register   Sign In
Calendar - Reoccuring events
#2

[eluser]xwero[/eluser]
You could add a reoccurring field with the id of the start event and generate the events for the current year.
The start event holds the information about the times it should reoccur and which period. This way you only have to add one extra field

|1|birthday me|01-01-2007|y0|
|2|birthday me|01-01-2008|1|
s,i,h,d,m,y can be used for the periods, you could even give the option to use complex periods as 2h30s which means every two and a half hours. You separate the string by looking for the last letter.
0 or any other number is for the times the event has to occur. 0 means always. 00 means from start event on.

If they start to browse you add reoccurring events before you display the calendar, this way it doesn't matter if they browse forward or backward they will always see their events. Checking the events recurrence will be easy because you can filter all numeric occurrences if you use the default value 1. Then it's a question of checking the strings.

It would mean you have a performance penalty but only for events that aren't already in the database.

I hope these tips can help


Messages In This Thread
Calendar - Reoccuring events - by El Forum - 09-14-2007, 05:33 PM
Calendar - Reoccuring events - by El Forum - 09-15-2007, 05:07 AM
Calendar - Reoccuring events - by El Forum - 10-06-2008, 06:03 PM



Theme © iAndrew 2016 - Forum software by © MyBB