News:

Wondering if this will always be free?  See why free is better.

Main Menu

Calendar Event Reminder

Started by HoverClub, January 28, 2011, 06:48:03 PM

Previous topic - Next topic

HoverClub

Link to Mod

Allows users to set a reminder for any calendar event.

Adds an drop-down reminder menu icon (alarm clock) to events in the calendar and on post with linked events.

The reminder menu allows users to select pre-set reminder periods from 1 day to 8 weeks.  They will be send an email reminder the selected period before any event.

Required Settings:
The calendar must be enabled in the admin control panel.
If you are also using my Event Registration mod mod then this mod MUST be installed AFTER installing the event registration mod.

Languages Support:
British English
Dutch
Italian
.. and the utf8 versions of all of them....


v2.31
Install bug in Italian language file
v2.30
fixed undefined error when event has been deleted but reminder still set
v2.20
include_once used to avoid PHP redeclare errors if code used in a portal block
v2.10
Won't send out reminders for events that have alerady started
Schedule changed to once daily @ 1:10am (to avoid other midnight tasks)
v2.09
fixed emailtemplate error for unsupported languages
removed some debug code that was preventing emails being sent
added support for utf8 languages.
v2.08
Fixed issue that stopped reminders being sent at times.
Now handles reminders correctly if the event date is changed AFTER a reminder has been set
v2.07
fixed template errors caused by attempting support for non-english language for email
v2.06
fixed language undefined errors in scheduled task
v2.05
changed redirect in calreminder.php to return to home page if topic # is undefined
reminder menu no longer visible to guests
reminder icon reduced in size
Menu no longer available on same day as event (it's too late!)
... etc.

TheListener

This mod looks good.

Would be ideal for my forum as it is for the local community and makes heavy use of the Calendar.

However on line 158 of my display template file I have this error.

Undefined Inex: View Week.

$url = '<li><a href="' . $scripturl . '?action=calreminder;eventid=' . $event['id'] . ';eventstart=' . $event['start_timestamp'] . (isset($context['current_year']) ? ';year=' . $context['current_year'] : '') . (isset($context['current_month']) ? ';month=' . $context['current_month'] : '') . (isset($context['current_day']) ? ';day=' . $context['current_day'] : '') . ($context['view_week'] ? ';viewweek' : '') . ';' . $context['session_var'] . '=' . $context['session_id'] . ';reminder=';


HoverClub

Edit the display template line 158 and replace:

$context['view_week']

..with

isset($context['view_week'])


.. I'll fix it at the next update (although it does work OK with the curve theme on RC4  ;D)

TheListener

Will do it this afternoon.

Another thing I have noticed is not all the events have the image next to them.

The calendar is open to guests if ya wanna take a peep.

www.miltonkeynesaware.co.cc/mkaforum

TheListener

#4
Getting these errors now.

http://www.xxxxxx/index.php?action=calendar
Apply Filter: Only show the errors with the same message
2: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument

Apply Filter: Only show the errors from this file
File: /home/xxxxxpublic_html/xxxxx/Themes/default/Calendar.template.php
Line: 383
   
http://www.xxxxxx/xxxx/index.php?action=calendar
Apply Filter: Only show the errors with the same message
8: Undefined variable: rems_done
Apply Filter: Only show the errors from this file
File: /home/xxxxx/public_html/xxxx/Themes/default/Calendar.template.php
Line: 383
   
377:    
/* The events are made up of:
378:    
title, href, is_last, can_edit (are they allowed to?), and modify_href. */
379:
foreach ($day['events'] as $event)
380:    
{
381:    
382:    
==>383:    if (!in_array($event['id'],$rems_done))
384:    {
385:    
$rems_done[]=$event['id'];
386:    
echo make_reminder_menu($event,null);
387:    }
// If they can edit the event, show a star they can click on....


Hmm since the suggested edit was applied I now see the following on the page.

Parse error: syntax error, unexpected ')' in /home/xxx/public_html/xxxxx/Themes/default/Display.template.php on line 158

HoverClub

Looks like you mis-edited the template.  Do a search and replace by copying the text from the post above.

Guests can't see the reminder icon in the calendar as, being guests, they haven't got an email address to recieve a reminder.

willemjan

Here is the Dutch translation:


$txt['reminder_mod_title'] = ' stuur mij een email voordat dit evenement begint';
$txt['reminder_mod_hours'] = 'uren';
$txt['reminder_mod_day'] = 'dag';
$txt['reminder_mod_days'] = 'dagen';
$txt['reminder_mod_week'] = 'week';
$txt['reminder_mod_weeks'] = 'weken';
$txt['reminder_noremind'] = 'geen reminder';
$txt['reminder_emailsubject'] = 'Evenement Reminder!';


I'm not shure if this part is correct. Could you place that in context for me?

$txt['reminder_mod_title'] = ' stuur mij een email voordat dit evenement begint';

HoverClub

#7
Embarrassingly, it's not actually used anywhere - I'll remove it next update  :-[

willemjan

Ok, then that is the Dutch translation ;) Have fun with it  :)

OCJ

#9
Im getting the same (log) errors as Brack1 with a clean install on rc4 or rc5 with no errors during package setup and no manual edits.

Adds up to about 200-300 errors per day.




http://************/events/index.php?action=calendar;year=2011;month=3

2: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument

File: /home2/************/public_html/events/Themes/default/Calendar.template.php (main sub template - eval?)
Line: 383


http://************/events/index.php?action=calendar;year=2011;month=3

8: Undefined variable: rems_done

File: /home2/************/public_html/events/Themes/default/Calendar.template.php (main sub template - eval?)
Line: 383


Andy

HoverClub

These aren't fatal errors - they should be fixed in the latest release though (05).

OCJ

#11
That was quick .... reminder5
:)

Seems like 1 error gone but still getting this one:

http://**********.com/events/index.php?action=calendar

8: Undefined variable: rems_done

File: /home2/*********/public_html/events/Themes/default/Calendar.template.php (main sub template - eval?)
Line: 379

doughboy99

Is there any way to set events to default to send emails to all members or individuals? We use calendar events for amongst other things recording who is on the swimming pool life guard rota and it would be great to be able to default to sending an email the day before each individuals "watch". Similarly we have some club events such as talk that we send a reminder about to our membership a couple of days before the event. It would be great if we could automate this via the forum.

Thanks for a useful mod.

HoverClub

It would probably be possible to send a bulk reminder email to all members but that's a guaranteed way to get listed as a spam site ::)

Why not set a reminder for yourself using this mod, then send a newsletter "reminder" (Admin->Main->News and Newsletters->Newsletters) to specific groups?

doughboy99

Thanks for the quick reply. I take your point about spam. In our case we have a restricted and small membership(a dive club) who actively want to be reminded about talks etc. H#ll try your suggestion about setting a reminder for myself as a prompt to email people.

In pool marshall rota is more of an issue for us as its a pain when someone forgets to turn up. I'll try taking a look at Outlook(shiver), although it sort duplicates enties somewhat.

hcfwesker

I haven't tested this MOD out, just wondering of their is a PM reminder option, instead of sending an email?

HoverClub

Quote from: hcfwesker on March 06, 2011, 04:18:04 PM
I haven't tested this MOD out, just wondering of their is a PM reminder option, instead of sending an email?

Nope - it's really the same thing as most people elect to get email reminders of a PM

72 454

Nice mod! Glad to see some interest in improving the Calendar/Events features. Tnx!  :)
SMF 2.0.11

OCJ

#18
Non-fatal error almost completely gone now ... I get an error when a guest selects a reminder from the calendar page - thats about it.

Adding to this post that one of my main uses for this mod is that the icon on the calendar splits up the events rather well - improves the standard calendar layout which makes it hard to see where one event title ends and the other begins - just the comma in small wrapped linked text. So it would be nice it it stayed rather than made invisible to guests...

petesky

I deleted my 0.7 but 2.0 cannot be installed right now on my RC4 ?!!!!

Advertisement: