CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Modify Hard Limit on Send Email To Contacts
Pages: [1]

Author Topic: Modify Hard Limit on Send Email To Contacts  (Read 1036 times)

chaseweb

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 0
  • CiviCRM version: 4.3.1
  • CMS version: Joomla 2.5.11
  • MySQL version: 5.1.65-cll
  • PHP version: 5.3.17
Modify Hard Limit on Send Email To Contacts
November 28, 2012, 11:52:54 am
Hi,

I have an org of older woman (womans club), and they have about 270 members.  There are several groups within the org and I would like for the members from the frontend to be able to use the Send to Contacts action, but some of the groups have more than 50 records.

The Mass Mailing is also setup, but as you know this is a little more complex than the Send Mail function, and I would like to increase the limit so that members can use this to mail to members of a group.

Is there a way to modify the limit for this.

Thanks
Corey

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Modify Hard Limit on Send Email To Contacts
November 28, 2012, 12:05:21 pm
Corey - that limit is hard-coded in a core php file in the codebase, which I think means you have to create a custom copy of that file (which is generally not a great thing to do since you'll have to keep 'fixing' it when you upgrade). Not sure of any other solution tho.

The code is in CRM/Contact/Form/Task/EmailCommon.php:

Code: [Select]
  CONST MAX_EMAILS_KILL_SWITCH = 50;
Protect your investment in CiviCRM by  becoming a Member!

chaseweb

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 0
  • CiviCRM version: 4.3.1
  • CMS version: Joomla 2.5.11
  • MySQL version: 5.1.65-cll
  • PHP version: 5.3.17
Re: Modify Hard Limit on Send Email To Contacts
November 28, 2012, 12:18:33 pm
Thanks Dave,

I figured it was hard coded.

Corey

chaseweb

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 0
  • CiviCRM version: 4.3.1
  • CMS version: Joomla 2.5.11
  • MySQL version: 5.1.65-cll
  • PHP version: 5.3.17
Re: Modify Hard Limit on Send Email To Contacts
November 28, 2012, 01:09:16 pm
Hi,

I specified my custom PHP settings
/home/wcradmin/public_html/civi.custom/sitephp

then I put the EmailCommon.php file into this directory and changed the setting down to 2 just to test that it will fail to send.

I sent to a group of 5 and the email still went out.

Must I build out the entire Directory structure underneath the sitephp folder?
Like this

CRM/Contact/Form/Task/EmailCommon.php

thanks
Corey

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Modify Hard Limit on Send Email To Contacts
November 28, 2012, 01:45:15 pm
Yes - you have to mimic the directory structure in your custom tree.
Protect your investment in CiviCRM by  becoming a Member!

chaseweb

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 0
  • CiviCRM version: 4.3.1
  • CMS version: Joomla 2.5.11
  • MySQL version: 5.1.65-cll
  • PHP version: 5.3.17
Re: Modify Hard Limit on Send Email To Contacts
November 28, 2012, 02:48:51 pm
Thanks Lobo...

Worked like a charm.

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Modify Hard Limit on Send Email To Contacts
November 28, 2012, 11:22:48 pm
Cool,

don't forget you will have to do the same thing (copy the existing php file, adjust the 50 limit) on each update, otherwise you will have the old code of a previous version for this file while the rest assumes that's the latest version (just banged my head way too long on a similar issue).

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

chaseweb

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 0
  • CiviCRM version: 4.3.1
  • CMS version: Joomla 2.5.11
  • MySQL version: 5.1.65-cll
  • PHP version: 5.3.17
Re: Modify Hard Limit on Send Email To Contacts
November 29, 2012, 04:48:57 am
Thanks Xavier for the reminder.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Modify Hard Limit on Send Email To Contacts

This forum was archived on 2017-11-26.