vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   Mini Mods - Email Reminder for inactive users (https://vborg.vbsupport.ru/showthread.php?t=237531)

TalkVirginia 05-26-2011 02:22 AM

I've decided to make things a bit easier with the mod so I'm planning on stripping out the logic that will base inactivity on last post and last visit. I'll be basing inactivity on last activity.

doobiefillin 05-26-2011 07:56 PM

Quote:

Originally Posted by TalkVirginia (Post 2197992)
Thank you for the info - I'll look into this and post a fix as soon as I can.

EDIT: AH, Ok.. I see the problem. If you don't mind and feel like you can make the change yourself. Here's how you can do it.

1. Open the <forum>\includes\functions_remindermail.php
2. Find:

Lines 91 and 212.
PHP Code:

"SET rmEmailDate = UNIX_TIMESTAMP(), "

3. Remove the comma at the end of TIMESTAMP() on both lines.

4. Save the file and you should be good to go.

If you decide you don't want to edit it yourself, I've attached a fixed file to this post. Just drop it in your forum includes folder.

Let me know if you have any other issues.

Thanks,
Jim

just uploaded the file, will let you know how it goes. thanks!

TalkVirginia 05-27-2011 03:23 AM

Uploaded a new version with the following changes/additions:

UpDate 2.2.0
=================
  • Removed logic to base inactivity on Last Post or Last Visit date. Inactivity is now based on Last Activity Date.
  • Removed option to select what to base inactivity on from the mod settings screen.
  • Fixed a couple typos in SQL update queries.
  • Exporting the following additional values which can be used in reminder email templates if desired:
    • $lastvisit - Formatted Date/Time Value - members last visit to the site.
    • $lastactivity - Formatted Date/Time Value - members last activity on the site.
    • $lastpost - Formatted Date/Time Value - members last post date on the site.
    • $lastreminder - Formatted Date/Time Value - Date member was sent last reminder email.
    • $days_since_lastpost - Number of days since member last posted.
    • $days_since_lastreminder - Number of days since last reminder was sent.
Please let me know if you would like other values made available.

Gene Steinberg 05-28-2011 04:57 AM

We got one serious, serious problem with your new version.

This option:

Usergroups
Which usergroups do you want to monitor for inactivity?

It doesn't work. I've been manually moving bounced messages to another usergroup, since you don't seem to have a proper bounce management system. But that group, although not checked, was sent email anyway. So suddenly I've got hundreds of bounces.

Ouch.

The only group that I checked is Registered Users, by the way.

You gotta fix that one ASAP, and then handle bounce management somehow, such as automatically moving bounced messages to a different usergroup.

Peace,
Gene

P.S. I'm curious about your paranormal research since I happen to host a nationally syndicated radio show, The Paracast, which covers the subject. :)

TalkVirginia 05-28-2011 07:47 AM

Ok will jump on fixing that now. Thanks.

As far as the paranormal research goes... what would you like to know?

TalkVirginia 05-28-2011 09:17 AM

1 Attachment(s)
Ok.. give these a whirl. :) This should fix the monitored usergroups issue.


functions_remindermail.php => forumroot\includes folder
process_inactive_members.php => forumroot\includes\cron folder


Please let me know if you run into anything else. Thanks

Gene Steinberg 05-28-2011 02:06 PM

Thanks.

As to the paranormal stuff, I suppose we can take that to my forum. :)

Peace,
Gene

Stefan118 05-29-2011 10:50 PM

1 Attachment(s)
I have given this mod another try with the newest update. (2.2.0)

Regarding the problem I had...
Could it be an old bug?
I have read all the posts of this mod, and found 2 other people who had the same problem.
https://vborg.vbsupport.ru/showpost....&postcount=194
https://vborg.vbsupport.ru/showpost....&postcount=296

I also have a question.
I have set the "Only send once?" at Yes.

What happens if a inactive user reads the mail, decides to log in again and then in a while becomes inactive again?

Thanks,
Stefan.

P.S.
Might want to take a look at this...
All my members have ID 0?

TalkVirginia 05-29-2011 11:25 PM

Quote:

Originally Posted by Stefan118 (Post 2201436)
I have given this mod another try with the new update.

Regarding the problem I had...
Could it be an old bug?
I have read all the posts of this mod, and found 2 other people who had the same problem.
https://vborg.vbsupport.ru/showpost....&postcount=194
https://vborg.vbsupport.ru/showpost....&postcount=296

Those errors should be fixed already. Also, did you drop in these fixed files?
https://vborg.vbsupport.ru/showpost....&postcount=406

Quote:

Originally Posted by Stefan118 (Post 2201436)
I also have a question...
I have set the "Only send once?" at Yes.

What happens if a inactive user reads the mail, decides to log in again and then in a while becomes inactive again?

Thanks,
Stefan.


They would get only one email regardless. Here's why:
  • If only sending once
    • Get members that have been inactive and have never received a inactive reminder.
  • else (Send emails more than once based on the following criteria)
    • Get members who have become inactive and have never received a reminder.
    • Get members who have been inactive and have not received an email since the last reminder was received. This is based on the number of days set in the frequency at which reminders go out ("How often should we send reminder email" setting.
    • SendReminders
  • If admin reminder report is enabled
    • Send Admin reminder report
That's all there is to it. Any questions? :)

In other words...

If you set the grace period for them to become inactive 60 days from their last activity date. On their 61st day they should get a reminder if they've never received one. This will set a flag so that the next time they become inactive for 60 days they won't get anymore emails if the mod is set to send only one email.

If set to send more than one.. same as above except the mod will look to see if they received an email previously.. and how many days it's been. For instances. If they have been inactive for greater than 60 days, let's say they have been inactive for 150 days and you have the "How often should we send reminder emails" setting set to 30 days, they should recieve an email every 30 days within that 150 day period which would be 2 times (150 - 61 = 89 / 30 = 2.966).

Make sense?

Stefan118 05-29-2011 11:31 PM

Ok, thank you.

I did also upload the 2 modified files.

I modified my last post... you were just ahead of me with posting.

Whow...
Not only the ID is 0...
When I click their names, all the data is gone!!!


All times are GMT. The time now is 07:46 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01602 seconds
  • Memory Usage 1,753KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete