# Question
Title: Profile is disabled OR it is not configured
I made the mistake of messing with an extension today, and now if I go to "search" for a contact using advanced search or find contacts, i receive this error: Sorry but we are not able to provide this at the moment. The requested Profile (gid=24) is disabled OR it is not configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance.

I have no idea what I would have done that would have triggered this error. Any assistance would be greatly appreciated.

Thanks, Matt

# Answer
The gid is the ID number of the profile. Something is calling for that profile, but it can't/won't pull it up for one of those various reasons.

Two factors to consider:

1. What is profile 24?
2. Why is Advanced Search trying to use it?

My hunch is that CiviHR creates a special profile and sets it to be used as the default search view. You can customize the columns you see when you run a search, and to do it, you set up a profile with the fields you want.

First, go into your profiles administration page and look for the one with ID 24 (looking both in the User-Defined Profiles and the Reserved Profiles). If there is none, that explains why it can't be found. If you find it, click Settings and check all the "used for" boxes. See if that helps.

Next, check your search preferences (Administer - Customize Data and Screens - Search Preferences) and see if a Default Contact Search Profile is set. Set it to None and save.
> 1 votes

# Answer
Running WordPress CiviCRM version 4.7.7

*May I suggest you post the traceback for the CiviCRM error?*

I am getting the **same error**, but I do not agree with the assumption that gid is referring to the profiles on **Administer/Custom Data and Screens/Profile**. There are actually two profiles (groups) in CiviCRM. This one refers to the **civicrm\_group** table, but there is another one in **civicrm\_uf\_group**. In the website I am administering the ids and names in both groups look almost identical, but civicrm\_uf\_group is missing gid=14 and the other table is not.

**So where do you Administer the civicrm\_uf\_group in the CiviCRM user interface? I cannot find any constraints between the 2 tables. I checked all civicrm\_uf\_\* tables and they do not reference gid=14, so where is it coming from? Even knowing which page or menu item is causing this error would be helpful.**

See the following CiviCRM log:

> May 29 15:06:44 \[info\] $Fatal Error Details = Array ( \[message\] =\> The requested Profile (gid=14) is disabled OR it is not \> \> configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance. \[code\] =\> )
>
> May 29 15:06:44 \[info\] $backTrace = #0 /../wp-content/plugins/civicrm/civicrm/CRM/Core/Error.php(371): CRM\_Core\_Error::backtrace("backTrace", TRUE)
>
> 1. /../wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/UFGroup.php(368): CRM\_Core\_Error::fatal("The requested Profile (gid=14) is disabled OR it is not configured to be used...")
> 2. /../wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/UFGroup.php(217): CRM\_Core\_BAO\_UFGroup::getFields("14", FALSE, 2, 5, FALSE, FALSE, "Profile", 5, NULL, 5)
> 3. /../wp-content/plugins/civicrm/civicrm/CRM/Profile/Page/Listings.php(143): CRM\_Core\_BAO\_UFGroup::getListingFields(2, 5, FALSE, "14", FALSE, "Profile", 5)
> 4. /../wp-content/plugins/civicrm/civicrm/CRM/Profile/Page/Listings.php(288): CRM\_Profile\_Page\_Listings-\>preProcess()
> 5. /../wp-content/plugins/civicrm/civicrm/CRM/Profile/Page/Router.php(124): CRM\_Profile\_Page\_Listings-\>run()
> 6. /../wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(312): CRM\_Profile\_Page\_Router-\>run((Array:2), NULL)
> 7. /../wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(86): CRM\_Core\_Invoke::runItem((Array:13))
> 8. /../wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(54): CRM\_Core\_Invoke::\_invoke((Array:2))
> 9. /../wp-content/plugins/civicrm/civicrm.php(1227): CRM\_Core\_Invoke::invoke((Array:2)) 10.internal function: CiviCRM\_For\_WordPress-\>invoke(Object(WP))
> 10. /../wp-includes/plugin.php(601): call\_user\_func\_array((Array:2), (Array:1))
> 11. /../wp-includes/class-wp.php(737): do\_action\_ref\_array("wp", (Array:1))
> 12. /../wp-includes/functions.php(952): WP-\>main("")
> 13. /../wp-blog-header.php(16): wp()
> 14. /../index.php(17): require("/var/www/vhosts/casem-acmse.org/httpdocs/wp-blog-header.php")
> 15. {main}

Any ideas?
> 0 votes

---
Tags: profile, civihr
---


# Question
Title: How do I find users who haven't opened any bulk mail from me recently?
Bounce handling is broken on my site, and so I'm trying to clean my list through several steps.

I'd like to get a list of users who have not opened *any* mailings in the recent past (say six months).

I keep getting a server error 500 when I try to use the advanced search \> mailings tab. But also I suspect that this search will simply give me a list of all contacts who have ever failed to open an email in the recent past, as opposed to the contacts who have never opened any emails.

Is there a way to do this?

Thanks!

# Answer
I think you may be able to use the Custom Search of Include/Exclude and make a Group that includes those who have opened, so you can 'exclude' them from a search of all possible recipients.
> 1 votes

---
Tags: civimail, custom-search
---


title: ACL for Contribution Page?

text:
# Question
Title: ACL for Contribution Page?
I'm using Drupal 7.43, and civicrm 4.7.4. Is it possible to limit access to a contribution page through Civicrm ACL's or Drupal roles? I want to set up a contribution page for new members to pay an initiation fee, but I don't want members to see it once they pay.

I can set up a drupal block, and have the link to the contribution page in the block, and assign the block to a role of new members who haven't paid the fee yet, and have the block disappear once they do, but they can still go to the url and access the contribution page.

# Answer
If your payment processor works with webforms possibly you could do it that way. At least for our configuation we have much better control over the visibility of drupal content rather than civicrm forms.
> 1 votes

# Answer
Another approach that would be suitable in some circumstances would be to use cividiscount and hence discount the membership fee by the amount of the initiation fee for existing members
> 0 votes

---
Tags: civicontribute, drupal, acl, roles
---


# Question
Title: Why don't links work from CiviCase Dashboard to filter by case type?
This works correctly on the Joomla demo server with 4.6.0, but not on my Joomla with CiviCRM 4.6.8. Not sure if this is a problem with the more recent CiviCRM versions, or something else in my configuration.

On the demo server, if you create cases in CiviCase, then go to the CiviCase dashboard, you can click on the numbers in the grid layout showing how many cases of what case type have what case status. This works by adding parameters to the URL of &status=2 and &type=2 (for example).

On my installation, the destination page seems to pick up status correctly, but even when type=3, it comes to a page giving an error that it couldn't find any cases, and shows the wrong search criteria for type:

```
 No matches found for:
Case Status(s) = Processing ...AND...
Case Type(s) In 1 ...AND...
Application = All Applications

```

Why does it think I want case type of 1, when the URL specified type=3 ?

If, from this screen, I select the Case type I want and click Search it gives a correct report as expected. But it's very inconvenient to have those direct links from the dashboard not work.

# Answer
This is fixed in newer versions

//find the code change here.. every time you click on dashboard link, in the CRM/Case/Form/Search.php file line number368,369, its hard coded to 1. it needs to be $caseTpe(which is getting the actual case type value)

```
 $this->_formValues['case_type_id'][$caseType] = 1;
  $this->_defaults['case_type_id'][$caseType] = 1;

```

change the above lines to use $caseType variable:

```
  $this->_formValues['case_type_id'][$caseType] = $caseType;
  $this->_defaults['case_type_id'][$caseType] = $caseType;

```

hope this helps some one
> 1 votes

---
Tags: civicase
---


# Question
Title: information about the underlying data-model behind civicrm (version 4.6)
where can I find that? I have a good knowledge of databases, so this information would help me a lot in modeling the civicrm-data with either contact-tags, groups.

# Answer
> 3 votes
There is some data information on the wiki:

I hope this helps you!

---
Tags: data-model
---


# Question
Title: 'View in browser' link on mailing gives 'Access denied' error
If I click on the 'view in browser' link on a mailing sent via CiviMail I get to a page on the website that says 'Access denied'.

Why is this not working?

# Answer
You need to change the permissions to allow the public to view the mailing.

This permission is called: 'CiviMail: view public CiviMail content'. This should be assigned to the anonymous role (or all user roles).

You also need to ensure that the mailing visibility is set to 'Public pages' for each mailing that you want to be available to view. This setting is found under 'Publication'.
> 3 votes

---
Tags: civimail, permissions
---


title: Tableau integration with Civicrm

text:
# Question
Title: Tableau integration with Civicrm
Can we integrate tableau with civicrm to get enhanced report functionalities?

# Answer
I use Tableau to enhance the reporting possibilities of CiviCRM.

Tableau can connect to many different data sources. I use a SQL connection to this, and this gives me full access to all the data tables in CiviCRM. I can then use Tableau to make interesting connections between different tables in an easy way.

I have not explored API connection, but I think that would be just as possible as SQL connection.
> 5 votes

# Answer
Yes you can, I know one CiviCRM user that uses Tableau to get his data reports from CiviCRM. I expect he will answer to this post too, his name here is Flying
> 1 votes

---
Tags: civireport
---


# Question
Title: How can I create branching scripts that a caller can use as part of a membership signup workflow, etc?
We're on Drupal and Civi 4.6.16.

I want to create forms with branching scripts for staff to use when doing membership signup calls, fundraising asks, etc.

I've created a webform using webform-civicrm that a caller signs into, with the contact and donor history info for the "target" contact, a "script" for the caller to use (using textarea fields), info on Activities to be created as appropriate based on the target's responses (like non-membership contribution ask - a one-on-one follow up meeting if the target agrees to meet).

But rather than have one long webform with various script options, I want to have the answers to questions asked in the script take the caller to a next step in that "workflow"- so if the target wants to contribute but does not want to schedule a follow up one-on-one meeting, then the script skips right to a page for the caller to get the target's contribution info while on the phone with the target.

However, if the target does agree to a one-on-one, then the script skips/branches to a page to create a non-membership ask activity/one-on-one meeting.

So have you done this? Are there public pages with examples?

Thanks for any info.

# Answer
Haven't explored this but my first thought is that conditional fields might be an option in webforms.

Based on whether the user checks this box or that box additional fields could appear. I think webform even supports doing multi-page forms and might be able to add those using this method.
> 2 votes

---
Tags: civicontribute, civimember, user, workflow, user-interface
---


# Question
Title: CiviCRM Dashboard Not Working - WordPress installation
I had no errors when installing CiviCRM (with Sample Data checked); I just had to manually create the database. The only "warning" was that my hosting company is using PHP 5.4.

I can see the CiviCRM link on the dashboard menu, but nothing drops down. On the right (CiviCRM Home) I only see the welcome message and some links. When I click the "System Status: Error" link, the welcome message blurb disappears, but no error message or anything else appears. Refreshing the dashboard data on CiviCRM Home does not help.

CiviCRM 4.7.7

WordPress 4.5.2 - fresh install on a subdirectory of my main site

No other plugins activated.

wp-content/uploads/civicrm/civicrm.settings.php - settings file is here

PHP 5.4.45

wp-content/plugins/files - full permissions (777)

BASEURL - http://paintballheroes.ablewebs.com

I am trying to test CiviCRM before we make the decision to use it for our not-for-profit organization (BC Balance and Dizziness Disorders Society http://www.balanceanddizziness.org). Any help would be greatly appreciated.

# Answer
> 1 votes
Check the **civicrm log** in /../uploads/civicrm/ConfigAndLog or /../plugins/files/civicrm/ConfigAndLog

Check the **error\_log**. phpinfo() will tell you where it is.

I had upgrade problems because the CONSTRAINT clauses were missing for my FOREIGN KEYS

---
Tags: dashboard
---


title: Adding Captcha to the forms

text:
# Question
Title: Adding Captcha to the forms
Hello I am trying to add captcha to both my donation page and my membership sign up page. I found the instructions to go to administer\>customize data\>profiles. I have added captcha to name and address, supporter profile and your resisgration info and it doesnt show up on the acutal form.

Any thoughts?

# Answer
> 6 votes
Solution was for the user to test this logged out.

---
Tags: forms, recaptcha
---


# Question
Title: How are civicrm_group and civicrm_uf_group related?
Running WordPress CiviCRM version 4.7.7

**In the log below, where is this gid coming from?** I checked all civicrm\_uf\_\* tables and there is no reference gid=14. Is there another relationship with another table I am missing?

The only reference to **Profiles** I can find in the UI is on **Administer/Custom Data and Screens/Profile**. There is no gid=14 listed.

In the website I am administering the ids and names in **civicrm\_uf\_group** and **civicrm\_group** look almost identical, but civicrm\_uf\_group is missing gid=14 and civicrm\_group is not.

So where do you Administer the civicrm\_group in the CiviCRM user interface?

Even knowing which page or menu item is causing this error would be helpful.

***See the following CiviCRM log:***

> May 29 15:06:44 \[info\] $Fatal Error Details = Array ( \[message\] =\> The requested Profile (gid=14) is disabled OR it is not \> \> configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance. \[code\] =\> )
>
> May 29 15:06:44 \[info\] $backTrace = #0 /../wp-content/plugins/civicrm/civicrm/CRM/Core/Error.php(371): CRM\_Core\_Error::backtrace("backTrace", TRUE)
>
> > 1. /../wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/UFGroup.php(368): CRM\_Core\_Error::fatal("The requested Profile (gid=14) is disabled OR it is not configured to be used...")
> > 2. /../wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/UFGroup.php(217): CRM\_Core\_BAO\_UFGroup::getFields("14", FALSE, 2, 5, FALSE, FALSE, "Profile", 5, NULL, 5)
> > 3. /../wp-content/plugins/civicrm/civicrm/CRM/Profile/Page/Listings.php(143): CRM\_Core\_BAO\_UFGroup::getListingFields(2, 5, FALSE, "14", FALSE, "Profile", 5)
> > 4. /../wp-content/plugins/civicrm/civicrm/CRM/Profile/Page/Listings.php(288): CRM\_Profile\_Page\_Listings-\>preProcess()
> > 5. /../wp-content/plugins/civicrm/civicrm/CRM/Profile/Page/Router.php(124): CRM\_Profile\_Page\_Listings-\>run()
> > 6. /../wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(312): CRM\_Profile\_Page\_Router-\>run((Array:2), NULL)
> > 7. /../wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(86): CRM\_Core\_Invoke::runItem((Array:13))
> > 8. /../wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(54): CRM\_Core\_Invoke::\_invoke((Array:2))
> > 9. /../wp-content/plugins/civicrm/civicrm.php(1227): CRM\_Core\_Invoke::invoke((Array:2)) 10.internal function: CiviCRM\_For\_WordPress-\>invoke(Object(WP))
> > 10. /../wp-includes/plugin.php(601): call\_user\_func\_array((Array:2), (Array:1))
> > 11. /../wp-includes/class-wp.php(737): do\_action\_ref\_array("wp", (Array:1))
> > 12. /../wp-includes/functions.php(952): WP-\>main("")
> > 13. /../wp-blog-header.php(16): wp()
> > 14. /../index.php(17): require("/var/www/vhosts/casem-acmse.org/httpdocs/wp-blog-header.php")
> > 15. {main}

# Answer
The short answer is that civicrm\_group has nothing to do with civicrm\_uf\_group. The former is actual groups, while the latter is profiles (groups of user-frontend fields).

If you have no profile with that ID, that would explain why you don't have access. The question really comes down to why you'd have a link there.
> 2 votes

---
Tags: wordpress, profile, error, 4.7
---


# Question
Title: Unexpected T_CLONE, expecting T_STRING (PHP 7, Drupal 7, Ubuntu 16.04)
On an Ubuntu 16.04 VM with PHP 7.x, I am seeing the following error when enabling CiviCRM in Drupal 7:

> ParseError: syntax error, unexpected 'clone' (T\_CLONE), expecting identifier (T\_STRING) or '(' in require\_once() (line 1 of /home/westernfriend/public\_html/sites/all/modules/civicrm/packages/DB/DataObject.php(207) : eval()'d code).

Is this due to incompatibility with PHP 7, a missing dependency, or perhaps something else?

# Answer
PHP 7 is not supported yet - see CRM-17789

Also: this and this

Update (Aug 2017): The information above was correct when it was written. Things have moved on and PHP 7.0 is supported from 4.7.12 onwards. Earlier versions of 4.7 don't run on PHP 7.0 and nor does any released version of 4.6. There are discussions about adding this to 4.6 - see the same ticket.

The most current information should be on CiviCRM PHP Requirements
> 7 votes

---
Tags: drupal, php, php7
---


# Question
Title: How to add the address column in a report
Im trying to add address columns to the report. Either a supplemental 1 or 2 address column. Ive got all the other criteria sorted but am strugling with the address.

So after the phone column i want to add the address. What code do i need to include?

Here is the code so far:

SELECT SQL\_CALC\_FOUND\_ROWS contact\_civireport.sort\_name as civicrm\_contact\_sort\_name\_a, contact\_civireport.id as civicrm\_contact\_id, contact\_b\_civireport.sort\_name as civicrm\_contact\_b\_sort\_name\_b, contact\_b\_civireport.id as civicrm\_contact\_b\_id, phone\_a\_civireport.phone as civicrm\_phone\_phone\_a

FROM civicrm\_relationship relationship\_civireport

```
         INNER JOIN civicrm_contact contact_civireport
                    ON ( relationship_civireport.contact_id_a =
                         contact_civireport.id )

         INNER JOIN civicrm_contact contact_b_civireport
                    ON ( relationship_civireport.contact_id_b =
                         contact_b_civireport.id )

    INNER JOIN civicrm_relationship_type relationship_type_civireport
                    ON ( relationship_civireport.relationship_type_id  =
                         relationship_type_civireport.id  )

```

LEFT JOIN civicrm\_phone phone\_a\_civireport ON ( contact\_civireport.id = phone\_a\_civireport.contact\_id AND phone\_a\_civireport.is\_primary = 1 )

WHERE ( ( contact\_civireport.contact\_sub\_type IN ( 'Residential\_Park') ) ) AND ( ( contact\_b\_civireport.contact\_type IN ( 'Household') ) ) AND (contact\_civireport.is\_deleted = 0 AND contact\_b\_civireport.is\_deleted = 0)

GROUP BY relationship\_civireport.id

ORDER BY contact\_civireport.sort\_name, contact\_b\_civireport.sort\_name

LIMIT 0, 50

# Answer
> 1 votes
You need something like this:

```
LEFT JOIN civicrm_address address_civireport ON contact_civireport.id = address_civireport.contact_id AND is_primary = 1

```

and then you need the column street\_address. Enough to get you a step further?

---
Tags: custom-reports
---


# Question
Title: adding a column to the standard relationships report in Contact Reports
Using the standard relationships report under Contact Reports, I would like to be able to add another column under Contact B. That column would pull the supplemental 1 address field.

Using the current template what do i need to add in order for that to work? Do i need to modify any other php files as well?

# Answer
> 3 votes
As ErikH stated it is always good practice to create a new extension or create a custom folder to override core files

So In order to add a supplement address in the report you need to add a new column to the report first

```
 'civicrm_address' => array(
    'dao' => 'CRM_Core_DAO_Address',
      'fields' => array(
      'supplemental_address_1' => array(
        'title' => ts('supplemental address 1'),
        'default' => TRUE,

      ),
    ),

```

The above code will add a column to the report and next you need to add address table to the from function

```
if ($this->_params['fields']['supplemental_address_1']){
    $this->_from .= "
        INNER  JOIN civicrm_address {$this->_aliases['civicrm_address']}
                     ON (( {$this->_aliases['civicrm_address']}.contact_id =
                           {$this->_aliases['civicrm_contact']}.id  OR
                           {$this->_aliases['civicrm_address']}.contact_id =
                           {$this->_aliases['civicrm_contact_b']}.id ) AND
                           {$this->_aliases['civicrm_address']}.is_primary = 1 ) ";

} else if (!empty($this->_params['country_id_value']) ||
  !empty($this->_params['state_province_id_value'] )
) {
  $this->_from .= "
        INNER  JOIN civicrm_address {$this->_aliases['civicrm_address']}
                     ON (( {$this->_aliases['civicrm_address']}.contact_id =
                           {$this->_aliases['civicrm_contact']}.id  OR
                           {$this->_aliases['civicrm_address']}.contact_id =
                           {$this->_aliases['civicrm_contact_b']}.id ) AND
                           {$this->_aliases['civicrm_address']}.is_primary = 1 ) ";
}

```

By doing the above you can achieve what you wanted

But still you need to add condition to your address table based on the location type or select only primary flag

I guess this helps !!!

# Answer
> 1 votes
Perhaps it will help you to read the documentation on CiviCRM Reports: https://wiki.civicrm.org/confluence/display/CRMDOC/CiviReport+Reference. It is not complete but it should help you on your way?

I would not recommend just changing the template, I would recommend creating an extension with your customized report. And then you would need to update the php files as well, check https://wiki.civicrm.org/confluence/display/CRMDOC/Create+a+Module+Extension#CreateaModuleExtension-Addareport

Or am I stating something which you already know by heart :-)

---
Tags: custom-templates, custom-reports
---


# Question
Title: Civicrm report:Bar chart and Pie chart support for different modules
Does civicrm support bar & pie chart report for all modules?? and if not then can we do it with custom templates?

# Answer
If it is problematic to do via civireport, drupal users can build charts off Views without needing to code. I have used both charts and charts\_highcharts to easily provide charts based on a range of civi entities
> 3 votes

---
Tags: civireport
---


title: Sticking quick search target tyoe

text:
# Question
Title: Sticking quick search target tyoe
While cleaning our contacts database, our users claimed that it would be beneficous to have the quick search bar remember the type of field to search in. In many cases it's helpfull to repeatedly search for zip codes or email addresses or stuff like that.

I had no luck finding information about accessing civi's session with js and therefore I wondered how to implement and decided to walk the extension way by feeding drupal with a cookie in my module's js file. What do you think?

```
CRM.$(document).ready(function () {
    /**
     * Save quick search type on select
     */
    CRM.$('.crm-quickSearchField').click(function() {
        var label = CRM.$(this).text();
        var value = CRM.$('input', this).val();
        jQuery.cookie('quickSearchLabel', label);
        jQuery.cookie('quickSearchType', value);
    });

    /**
     * Set quick search type on load
     */
    var quickSearchType = jQuery.cookie('quickSearchType');
    if (quickSearchType) {
        var quickSearchLabel = jQuery.cookie('quickSearchLabel');
        var label = quickSearchLabel ? quickSearchLabel : "Suche";
        var value = quickSearchType;
        // These fields are not supported by advanced search
        if (value === 'first_name' || value === 'last_name') {
            value = 'sort_name';
        }
        KompiModsLib.radioSelect("input[name=quickSearchField]", value);
        CRM.$('#sort_name_navigation').attr({name: value, placeholder: label}).focus();
    }
});

```

And: would it be valuable to add it to the core?

# Answer
That's a good idea. Here is a refinement of your patch that works it into core using `localStorage`, which is not CMS dependent.

https://github.com/civicrm/civicrm-core/pull/8485
> 1 votes

---
Tags: search, ui, core
---


title: Display CiviCRM Admin Menu in Drupal

text:
# Question
Title: Display CiviCRM Admin Menu in Drupal
Is there any way we can display CiviCRM Admin Menu in Drupal context ? like on any view page we want both drupal and civicrm menus.

# Answer
Yes. You can do this by enabling the CiviMenu drupal module:

> CiviMenu allows you to display the CiviCRM menubar on non-civicrm pages of your website.
>
> This module provides an invisible Drupal Block which loads the CiviCRM menubar. By default the block will display the menubar on every non-civicrm page of your website. Simply edit the block to refine exactly which pages the menubar appears on and which users have permission to see it.
>
> Note that nothing displays in the block (the menubar will always be at the top of the screen), so it doesn't matter which region of the page you add it to.
> 6 votes

# Answer
If you don't need too many items - you can put them in the Drupal Toolbar - Shortcuts! You can also install Shortcuts by Role - and then give users with different roles different buttons in their Drupal Toolbar.
> 1 votes

---
Tags: admin, menu
---


# Question
Title: Can I record contributions and pledge payments in a "Batch Data Entry" of type pledge payment?
When using a data entry batch of type "Pledge Payment" can I record stand-alone contributions as well as pledge payments in the same batch?

(It seemed like I could do this in 4.6.0, but its not working in 4.6.3. In 4.6.3 I get the following message for contacts with no pledge selected: "Please correct the following errors in the form fields below: You can not record two payments for the same pledge in a single batch." )

# Answer
While in 4.7.7 (sorry, don't have a 4.6.3 environment to test), it is technically possible to record stand-alone contributions in a batch created for pledge payments by leaving the "Open Pledges (Due Date - Amount)" field blank and selecting the desired financial type, in a recent session at CiviCON 2016, Joe Murray indicated that best practice would be to record each type of contribution with the batch entry category that it falls into (i.e. use contribution for stand-alone contributions and pledge payment for pledge payments), although I clearly see the convenience of being able to record multiple contribution types in a single batch entry.

Hope this helps, Tamar
> 2 votes

---
Tags: civicontribute, civipledge
---


title: Fee based on payment processor

text:
# Question
Title: Fee based on payment processor
Is there a way to enable a different price set or enable a fee (like a tax) dependent on the payment processor?

For instance if they select "Credit/Debit" as the payment processor a certain fee will be applied (3% or whatever).

Or if they select "Credit/Debit" a specific price set with the reflective price changes would appear which would be different than a "Pay Later" price set?

# Answer
> 1 votes
Unfortunately I don't think this is possible to do without a small amount of development work.

If you did want to add this as a feature there are several approaches:

1) You could modify the contribution template file yourself (or pay a developer) to add some javascript in order to do this. You would probably also need to configure the page to have a price set field that is the "credit card fee" or something similar. There is more information about how to append a template page here:

https://wiki.civicrm.org/confluence/display/CRMDOC/Page+Templates

2) You could contact the core team here and request a new feature using the paid issue queue: https://civicrm.org/paid-issue-queue. CiviCRM has a new monthly release cycle so your feature could be built relatively quickly.

Best

Jamie

---
Tags: payment-processor, price-sets
---


title: Alerting Users of CiviCRM Maintenance

text:
# Question
Title: Alerting Users of CiviCRM Maintenance
I thought I had seen, and used, this feature in the past, but perhaps it was a different CRM product I was testing. How do I put a scrolling alert up to inform users of system maintenance, or new feature improvements, or a friendly "replace the used toilet paper rolls" message? (Ok, if you do the last one, you may need to seek help, but you get the idea.) I can't seem to find it via menu diving or Google-Fu.

(I'm using Wordpress, but I would think it would be a core feature.)

# Answer
> 1 votes
I'm not aware of such a feature.

A (somewhat drastic) workaround would be to remove "access CiviCRM" permission from your users during maintenance.

You could probably customize the "access denied" message that WP gives, to be a bit more friendly.

# Answer
> 1 votes
Since the question asked is generic - I'll add that in Drupal - you would invoke the maintenance mode screen - on that you can display a customized message.

---
Tags: dashboard, user
---


# Question
Title: Is there a way to prevent two 'home' addresses for a contact?
I'd like to prevent a single contact from having two addresses with the type 'Home' (or 'Work', etc.). Is there a CiviCRM configuration, or an extension, that provides this functionality?

# Answer
The form validation in the user interface will prevent this. So there's no need to have a setting that would prevent it.

But the API does not prevent it: you can, for example, create a second Home address for a contact through the API. There is no API configuration or option to prevent this.

Thanks @Coleman for pointing this out.
> 1 votes

---
Tags: addresses
---


# Question
Title: Assigning only a part of a contribution to a Contribution Page
Our organization just had its annual fundraising dinner/auction. People paid in one transaction for a number of things: auction items, raffle, sales tax, etc., as well as donations designated for a number of things. Most of this am recording in Civi using a Price Set with Text/Numeric Quantity for the various fields.

However, undesignated donations are going to a specific campaign that is a challenge match. I have also set up a Contribution page for this Matching Challenge. I want to be able to record the amount from only one of the price fields against this Matching Challenge Contribution Page - so the widget on our website is accurate among other reasons.

For instance, I might record this as a transaction:

```
Name: Joe
Total Amount: $175
Payment Instrument: Credit Card
Price Field: Auction = $100
Price Field: Raffle = $25
Price Field: Match donation = $50

```

So, only the $50 should be counted to the Matching Challenge contribution page.

Is there any way to do this other than making it two transactions, which could lead to confusion?

# Answer
As far as I know, since the link to the contribution page is determined by the source of the contribution as opposed to its individual line items, I do not believe this is currently possible. Even if you recorded two separate contributions, unless you have a corresponding contribution page for each (which would indeed be confusing as you state), they would both still be associated with the same contribution page

You may want to research alternative methods of pulling this information by line item financial type into an alternative widget - my knowledge of widgets is limited.

Hope this helps, Tamar
> 1 votes

---
Tags: civicontribute, contribution-page
---


title: Custom Report Template

text:
# Question
Title: Custom Report Template
Keep getting message

> Template not found. Could not find the report template. Make sure the report template is registered and/or url is correct.

I followed a guide in setting up a custom report. I created a new custom PHP path and a custom template path. Within both of those the guide said to recreate the path of the original report. ie: /CRM/Report/Form/Contact/then the .tpl placed in there. The path for custom PHP was also the same with the report PHP placed in there.

In the guide it said copy the existing tpl file (in this case it was called Relationships) and then edit it to include the following line:

```
 *}
{include file="CRM/Report/Form.tpl"}

```

It then said save it as the new file name. In this case ResidentialCommunities.tpl and refreshed

I then registered the report in Administer\>Civireport\> Register Report

In the settings under Url it shows /Contact/ResidentialCommunities Under Class it shows CRM\_Report\_Form\_Contact\_ResidentialCommunities

It registers. Then when going to Contact and Contact Reports then add new report it shows under Contact Reports the clickable link to my custom report. Then I click it and it throws the error. I'm certain that there is an issue with the Url field, but can't see why.

# Answer
> 2 votes
Not sure which one you used - but this is still one of the best guides out there:

https://alastaira.wordpress.com/2011/03/17/civicrm-creating-a-custom-report/

Note: the .php goes into your custom\_php and your .tpl goes into your custom\_templates (and you must set these paths in the Administer -\> System Settings -\> Directories: Cutom PHP Path Directory and Custom Templates).

After adding these paths and putting the .tpl and .php into place:

Clear caches: Adminster -\> System Settings -\> Cleanup Caches and Updates Paths - and hit the Cleanup Caches button.

---
Tags: custom-templates
---


# Question
Title: How to create a free Membership sign-up?
Can someone tell me the correct setup for a FREE Membership? Cannot figure out what to check to get rid of the error "One of parameters (value: ) is not of the type Integer", which occurs after the second page.

Doesn't seem to be a way to do this with the word "contribution" everywhere and trying to set a price to $0 didn't work like some other posts listed.

Just want a clean membership page where joining is free and no hint of needing to contribute.

# Answer
> 1 votes
Here's an Example of a clean FREE Membership page with no hint of needing to contribute! On the Contribution Page Config -\> Memberships Tab -\> make sure you select the Membership.

Note 1: you'll want to add some anti-spam control - like add a reCAPTCHA to a profile that you expose on your Contribution Page

Note 2: In Drupal we can sync Membership Type/Status -\> to Drupal role - and can then create Member only content pages. Not sure if you can do that in Wordpress - but that's often our use case for a FREE Membership.

# Answer
> 1 votes
You simply set the membership price to zero. On the demo go to Membership Types (un/pw is demo/demo as usual) and change the price of one of them to zero and see what happens at the membership signup/renewal page.

As per Pete's comment you may not need a membership at all, but just have them sign up to a group instead.

But if membership makes sense, and you need member role sync to Wordpress, I've used Tadpole's Wordpress CiviMember Role Sync Plugin but I see they are recommending a new one on the page.

# Answer
> 0 votes
I'm with Pete. Unless you have dues or expiration, you shouldn't use CiviMember to manage your membership. Disable it so your colleagues don't get confused.

Then, create a group and then a profile that adds people to the group. Link to that profile in "create" mode and make that your membership signup form.

---
Tags: wordpress, civimember
---


# Question
Title: Haven't seen this in a while: jQuery is not defined on CiviMail 4.6.16
Yo dudes, let's get the con started with this classic! Haven't seen this beast in a while.

1. recently updated to 4.6.16
2. theme Seven
3. ran update.php after upgrade
4. cleared Civi and Drupal cache
5. Drupal cache off

Still the issue with field selects and jQuery error is happening (attached images). Feeling kind of duncey here. Any ideas?

Stuart

# Answer
Installing jQuery Update module fixed the issue. The site was running a 'stock' Drupal 7.43 with no modules except Views, cTools and Webform.
> 0 votes

# Answer
What happens if you change themes to one of the basics? This looks somewhat similar in end result to the Backbone errors that are occurring with some of the themes. Do you see errors on the Manage Events -\> Online Registration page also?
> 1 votes

# Answer
Hmm--in theory Drupal jQuery Update shouldn't make a difference. Ye olde jQuery in Drupal is the reason CiviCRM has its own `CRM.$` or `cj` instead of regular `$` or `jQuery`.

Something must be using the wrong one. If I had to guess, I'd say that some code isn't within a closure.
> 1 votes

---
Tags: civimail, jquery
---


title: Why are country names not translated

text:
# Question
Title: Why are country names not translated
We are using CiviCRM 4.7 on Wordpress 4.4 in German Language and have switched the standard language to German. I have noticed that the country names are still in English.

* Is there a specific reason for this?
* What would be the correct steps to translate?
* Do we need to translate manually all country names in the civicrm\_country table?

# Answer
I am not using the German version, but have translated the Norwegian version of the country names. There I also have just copied the English version, and only changed the name of my own country.

One of the cases we use country names most often, is when sending postal mail. Norwegian post men reads Norwegian, but French and German post men don't understand Norwegian country names. They do however understand English country names.

Therefore; **English country names=higher probability for postal mail to reach its destination abroad**
> 4 votes

# Answer
We couldn't find an official translations for country names for ISO 3166-1 into languages other than English and French. If you could provide them that would be great. The Canadian government publishes its list of recognized countries related to this standard; perhaps Germany's foreign Ministry does something similar.

Check on transifex if the country names are able to be translated there. If not and you would like to provide translations, contact Mathieu Lufty or comment back here with your contact info and I will.

I created an issue on JIRA for followup by Mathieu https://issues.civicrm.org/jira/browse/CRM-18015 but it appears that there is no systemic problem with translations of country names. So there is likely a problem unique to your installation. Please try to reproduce on the demo site (dmaster.demo.civicrm.org) and reopen the issue with details if you are successful.
> 4 votes

# Answer
This is my fault, sorry about that.

The short answer, is that I think we should revert a change related to country names. This could probably be done for CiviCRM 4.7.9.

Long answer and mea culpa:

I am one of the people responsible for pushing new strings to Transifex when a new CiviCRM release is published.

When strings are pushed, we also review new strings to make sure that we are not pushing too many strings with typos, bad programming, etc. For CiviCRM 4.7, the release process was a bit different, and the strings were pushed to Transifex much later than usual. It's only then that I noticed that the country names were all uppercased (CRM-16876).

I disagreed with the change and wanted to have more feedback before pushing the strings to Transifex. It would have required translators to re-translate ~ 350 country names. However, I was backlogged by other important issues in 4.7, so I had not gotten to it yet.

To address some arguments mentioned in this thread: should the (foreign) country name on postal labels always be in English? Should it be in capital letters?

* Maybe, but that should be a mailing format option. We could probably add that pretty easily in core, in a similar way that we have {contact.state\_province} (abbreviation) and {contact.state\_province\_name}.
* Currently, contribution forms with a country field do not look good. A list of uppercase names is hard to read and unusual.
* As someone using CiviCRM in French, I would expect that other francophone countries would have their French country name.
* Having a translated country name is also important for backend forms, where staff may not know the name of a country in English.

If you are interested in improving non-English support in CiviCRM, please subscribe to the "intl" discussion mailing-list (also known as the "Translation Working Group"). You do not need to be a programmer. We need translators, users and anyone using CiviCRM in non-English to give more feedback to help guide CiviCRM development.

We also have a list of language/locality-related items that we have identified as needing improvement. One big challenge is also raising awareness on what is a translation challenge. It's not always easy to know what can affect non-English users.
> 4 votes

---
Tags: i18n
---


# Question
Title: How do I add CiviCRM fields to a layout box / container in a form created using webform-civicrm?
I'm on Civi 4.6.17 and Drupal 7. I've created a webform using the Drupal webform-civicrm module. I also have the Drupal webform layout module installed. I've added a new layout box (which seems to mean the same thing as 'layout container' as referred to at the Drupal webform layout module page). How do I now add fields to my new layout box? Do I need to have the Drupal Form Builder module installed as well to add fields to the layout box?

# Answer
when you're on the Webform tab - you can drag and drop your fields into the Layout Box - here's what it will look like:

And re: the second part of your question - no - you don't need Drupal Form Builder. When you've downloaded and enabled webform\_civicrm module - you'll see a CiviCRM tab (on the far right side) and this is where you tell the module to pull in certain Fields from your CiviCRM:
> 5 votes

---
Tags: drupal, webform-civicrm
---


title: Household member last name shows twice

text:
# Question
Title: Household member last name shows twice
When we look at the household member is and pull up a record, it shows the household member last name twice, eg Bartlett,Bartlett. However when you click on this it shows the proper name, eg Peter Barlett.

Any ideas

# Answer
> 1 votes
Fixed this after looking at the import of data. Remedy was to highlit the double name and click edit then save. it reset the data correctly. Did this via a bulk update

---
Tags: contacts, households
---


# Question
Title: Memberships ending a day early before auto-renew
I have an issue where all monthly auto-renew members expire on the day that they will be charged. The payprocessor charges on the same day of the month that the membership was created. eg. 01/08/16, 02/08/16, 03/08/16 etc. but it may happen at 11pm....it's never the same time of day per customer. This leaves the members in an expired state since Civicrm api job process\_membership expires the membership on that same day, the "end\_date". I'd say that's clearly unwanted behavior for an auto-renew member! Civi calculates the end\_date by incrementing the month by 1. But the end\_date should be padded by a day if a member is to get a whole month of uninterrupted membership.

Is there a way to define a month, or otherwise work around this within the UI?

end\_date seems like an unfortunate choice for field name, since it falls within the date range of membership but apparently is definitely not being treated like the other days in that range. IMHO, valid\_through makes a lot more sense since it's more clear as to how it should be treated.

It seems like there are two options. 1) redefine the monthly membership period as month++ day++ or 2) reconceptualize end\_date as valid\_through and expire when that day is over. Even though I think #2 makes more sense, I think #1 may be easier. I've tested the daily member and it doesn't expire on the "end\_date",...I'm thinking there's a check to see if the end\_date is equal to the current date or start\_date.

# Answer
We set our memberships to and end date of 30th June then add a Grace period of 1 month to allow for collection of member fees. You can set grace periods and define the length of that period. Maybe this will assist you. Essentially for us our members are current as at 30th June then on 1 July they fall into a status of Grace, then if renewed they are current again or after 31 July they fall into expired member status.
> 3 votes

---
Tags: civimember, payment-processor, recurring-contributions
---


# Question
Title: Version 4.7.3: TCPDF package seems to be missing
I recently upgraded to vesion 4.7.3 (I'm running under Wordpress), and for some reason the TCPDF package was missing!

This led to the error: "Warning: opendir(/nhldata/631/106631/data/web/predigerforum/htdocs/wordpress/wp-content/plugins/civicrm/civicrm//packages/tcpdf/fonts/): failed to open dir: No such file or directory in /nhldata/631/106631/data/web/predigerforum/htdocs/wordpress/wp-content/plugins/civicrm/civicrm/vendor/tecnickcom/tcpdf/tcpdf.php on line 4148 TCPDF ERROR: Could not include font definition file: helvetica"

...when trying to create labels. I copied the directory "tcpdf" from the previous version into the packages directory and it seems to be OK now.

Perhaps there is a slip up in V 4.7.3, because I did nothing more than the normal upgrade process.

# Answer
> 2 votes
In 4.7.3 the TCPDF package was moved to civicrm/vendor/tecnickcom from civicrm//packages/tcpdf.

I just tested on a WP 4.5.2 and CiviCRM 4.7.8 install and was able to create mailing labels.

Can you give us the steps to reproduce? This may be a bug that needs an issue filed at https://issues.civicrm.org

One additional thought - try and empty the caches in WP the url is `https://yourdomain.org/wp-admin/admin.php?page=CiviCRM&q=civicrm/admin/setting/updateConfigBackend&reset=1`

---
Tags: wordpress, upgrade, pdf
---


# Question
Title: How can I specify which location type address to use for a proximity search
I collect both home and work address data for contacts. I assume - although I've not yet tested it - that the default location type is used when a proximity search is carried out.

I have work address set as my default, but want to do a proximity search based on home address.

Anyone know if this can be done, and if so how?

# Answer
> 1 votes
If you're on Drupal you can do this via views (where you have full control over which field types you pull in).

Here's a good example: Views Proximity Search on Latitude / Longitude

---
Tags: custom-search, location-type
---


# Question
Title: Can't Edit CiviContribute Pages after URL Change
Our website is being hosted by CiviHosting, but our Domain and Email are with another hosting company. The other hosting company just changed the DNS to point to CiviHosting, so that our domain would work with the CiviHosting account, and now I can't edit the contribution pages I made (or create a new contribution page). Specifically, I went to contributions \>\> manage contribution pages and then chose "configure" and then "Title and settings" for one of the pages and it redirected me to the /wp-admin Wordpress dashboard.

I tried a different page same thing.

I tried creating a new page and it let me type everything in but when I hit "save" it took me back to the /wp-admin page.

I tried deactivating and reactivating the plugin. Didn't work.

I tried removing all the files from the server through FTP, and reinstalling a brand new installation of CiviCRM. Didn't work.

I removed the new installation and put my old civicrm files back. Didn't work.

I have been Google Searching for a while and I tried finding config.settings.php as many sites suggest, but the only thing I could find was config.settings.php.template which I did attempt to modify in the way they described (changing the base URL) and that didn't work either. I changed it back to the original and re-uploaded it via FTP.

I looked through civicrm.config.php in case that was the file I was supposed to modify, but couldn't find a place to change the URL.

I tried going through the settings menu of CiviCRM, specifically the resources and directories paths and they all look like relative references (see attached) so I'm not sure what I'd change.

If you go to the actual pages, they do work, but I have no way of modifying them... (here's an example live page: http://sweetfields.org/civicrm/?page=CiviCRM&q=civicrm/contribute/transact&reset=1&id=1)

Any idea what broke and how to fix it?

Thanks!

UPDATE: I just noticed that when you click on the link I provided in this post, it is referencing an old version of the site... I removed the black login bar at the top of the page. If you go to sweetfields.org now you'll notice the black bar is gone but for some reason it's there for the CiviContribute page... the plugin must be somehow referencing old files?

UPDATE 2: Found the file! But, it already has the correct URL in it for the base\_url: " define( 'CIVICRM\_UF\_BASEURL' , 'http://sweetfields.org/');" so I'm guessing that's not the problem?

UPDATE 3: Should I delete all tables in the database that start with "civicrm\_" and delete all files and then try re-installing?

# Answer
> 1 votes
For a domain change, look at the civicrm.settings.php file the 'CIVICRM\_UF\_BASEURL' is the field you are looking for.

For CiviCRM version 4.7.x this will be in wp-content/uploads/civicrm/
For CiviCRM versions 4.6.x and lower this will be in wp-content/plugins/civicrm/

You may also need to make changes for WP, but this is what you'll need to start with for CiviCRM. In addition, the CIVICRM\_UF\_BASEURL setting must match the Site Address (URL) in the WP General Settings.

Update: Ensure that CIVICRM\_UF\_BASEURL reads as below:

```
define( 'CIVICRM_UF_BASEURL'      , 'http://sweetfields.org');

```

---
Tags: wordpress, civicontribute, contribution-page, urls, resource-urls
---


title: Cron error after upgrade to 4.7.1

text:
# Question
Title: Cron error after upgrade to 4.7.1
Upgraded from 4.6.11 to 4.7.1 and now this this error when running /wp-content/plugins/civicrm/civicrm/bin/cron.php

> Fatal error: Uncaught exception 'Exception' with message 'Function "is\_admin()" is missing, even though WordPress is the user framework.' in /home/xxxx/public\_html/wp-content/plugins/civicrm/civicrm/CRM/Utils/System/Base.php:261 Stack trace: #0 /home/xxxx/public\_html/wp-content/plugins/civicrm/civicrm/CRM/Utils/System.php(219): CRM\_Utils\_System\_Base-\>theme('PEAR\_Error('DB Error: insuf...', -26, 16, Array, ' \[nativecode=10...') #5 /home/xxxx/public\_html/wp-content/plugins/civicrm/civicrm/packages/PEAR.php(564): DB\_Error-\>DB\_Error(-26, 16, Array, ' \[nativec in /home/xxxx/public\_html/wp-content/plugins/civicrm/civicrm/CRM/Utils/System/Base.php on line 261

# Answer
> 1 votes
On a WordPress site with CiviCRM 4.6.10 I had the same problem but switching from the "URL" to the "CLI" method of executing cron fixed the problem.

# Answer
> 1 votes
An issue has been filed for this in the CiviCRM bug tracker.

See https://issues.civicrm.org/jira/browse/CRM-18514

# Answer
> 0 votes
I see from the above that you are using the php cli method. The credentials that it is looking for is a CMS User (WordPress) with sufficient permissions in CiviCRM to run the jobs.

I just tested on 4.7.8 CiviCRM with WP 4.5.2 with the following syntax

```
/usr/local/php56/bin/php /home/user/htdocs/civicrm/wp-content/plugins/civicrm/civicrm/bin/cli.php -u cronuser -p somepassword -e Job -a execute

```

---
Tags: upgrade, cron-job, error, 4.7
---


# Question
Title: System Status: Error "Cron Not Running" after update to 4.7.4
So going through CiviCRM, this error keeps popping up:

> Cron Not Running
>
> No cron runs have been recorded.

Unfortunately, I have contacted my hosting provider and asked what cron isn't running related to CiviCRM, and they could not help me unless they knew the name of the cron. I tried seeing what it could be but I cannot find any information on this. I never had this error prior to updating to 4.7.4 from 4.6.10. I tried running a cron in the backend, like system update check, to see if it would fix it but it did not. What can I do to solve this issue?

Thank you.

# Answer
A similar-sounding bug report has been filed here:

https://issues.civicrm.org/jira/browse/CRM-18514

There are scattered reports of cron-related issues in 4.7 but people have been not giving detailed enough information to really pin the problem down. Can you say exactly how you have your Civi cron jobs configured to run? From your question it is not clear that you *ever* had cron set up correctly... the warning message about that is a new feature in 4.7 - it may simply be telling you about a problem that's been there all along.
> 2 votes

# Answer
I'm not sure what you are using to run your crons but in the past I had a similar problem to this and it turned out to be a permissions problem in cli.php. Have a look at root/.../wp-content/plugins/civicrm/civicrm/bin/cli.php and ensure that it is executable.
> 0 votes

# Answer
This was reported and detailed here: https://issues.civicrm.org/jira/browse/CRM-18089

Using the php cli method. The credentials that it is looking for is a CMS User (WordPress) with sufficient permissions in CiviCRM to run the jobs.

I just tested on 4.7.8 CiviCRM with WP 4.5.2 with the following syntax

/usr/local/php56/bin/php /home/user/htdocs/civicrm/wp-content/plugins/civicrm/civicrm/bin/cli.php -u cronuser -p somepassword -e Job -a execute

I can confirm this worked with Drupal as well.

Tested with the URL method on both WP and Drupal. CiviCRM 4.7.8

Both worked with the configuration detailed https://wiki.civicrm.org/confluence/display/CRMDOC/Managing+Scheduled+Jobs#ManagingScheduledJobs-URLmethod

The only caveat: Both the user's password and the site key need to have no special characters. Once I cleared that up, crom was able to run with the URL method.
> 0 votes

---
Tags: wordpress, cron
---


# Question
Title: Multilingual support and database issues -- how many languages?
I am considering enabling multiple languages (in CiviCRM 4.6.12 with Drupal) and would like to hear from those of you who've done so about your experiences. Specifically, how many languages are you using, and have you observed any database problems as a result?

I read in a discussion here that enabling more than 2-3 languages can lead to database problems. This presentation from CiviCon 2013 gives the number as 3-4. Has anyone successfully used more than 4?

Are there other pitfalls of multilingual support I should be aware of, even if I stick to only 2-3 languages?

# Answer
So the problem is that each new language is stored as a separate column for each translated field (eg title, body...), so the more fields that are translated and the more new language you add, the sooner you will hit a limit of mysql on how many columns can be set. As for the exact number, it depends as well on the type of content you store, mysql has a longer explanation, but 2 or 3 is what I've tested without reaching that limit: http://dev.mysql.com/doc/refman/5.7/en/column-count-limit.html

Other than that, works pretty ok, but keep in mind that because the structure of the database is changed, it becomes impossible to revert to a single language version.
> 1 votes

# Answer
In addition to the answers of Xavier and Mathieu I would like to add some non-technical aspects for your consideration.

IMHO a multilanguage set up considerably raises complexity in a lot of ways for users and admins alike. Think auomated emails, online forms or extensions just to name a few. All issues arising from those can probably be dealt with but it is definitely time consuming and not fun at all (also given the lack of documentation)!

In short, unless it is absolutely necessary I would recommend to stick to a single-language set up.

PS: Even eithout multi-language you can use CiviCRM's user interface in various languages - however some elements (such as option groups, contribution status...) wont be translated...
> 1 votes

# Answer
I did some more testing, and managed to get it up to 8 languages, if using the Barracuda file type in MySQL. In the default mode (Antelope), I could only enable 6 languages.

The main issue is the "civicrm\_event" table, which has a lot of text fields.

WARNING: this has not been extensively tested. Use at your own risk.

To try it:

In the MySQL configuration (ex: /etc/mysql/conf.d/civicrm.cnf), add:

```
innodb_file_per_table = 1
innodb_file_format = Barracuda

```

(then restart MySQL)

Then alter the civicrm\_event table to use dynamic allocation for all varchar/text columns:

```
drush civicrm-sql-cli

alter table civicrm_event ROW_FORMAT=DYNAMIC;

```

I documented this in: CRM17827
> 0 votes

---
Tags: i18n
---


# Question
Title: Price set contribution field won't accept negative amounts?
Price sets give you the tremendously useful ability to add a price field in which a user can enter an arbitrary amount. This is done by choosing an Text/Numeric field type, setting its value to '1' and NOT ticking 'Display amount'.

However, we want to use this to create an arbitrary-sized discount for admin users, and Civi doesn't seem to allow negative numbers in this field.

As you can see from the attached screen shot, the negative entry in our 'arbitrary amount' field has been ignored.

It's perfectly possible to make discounts of fixed amounts in a price set - the screen shot shows that our fixed discount has been included in the price calculation.

What would need to happen so that this 'arbitary amount' field can accept negative amounts?

Thanks for your help!

Drupal 7.43, Civi 4.6.17

# Answer
Ah - I strongly suspect this is a 'rule'/'validation' (either in the javascript or the form layer) - to ensure people donate extra as opposed to giving themselves a discount.

The workaround is obvious: create an Arbitrary Amount similar to how you created the Discount Amount - or do you need it to be this type of field?
> 1 votes

---
Tags: civievent, price-sets
---


# Question
Title: How To View Documents Uploaded Through Custom Profile
I created a custom profile field which has an upload field to allow users uploaded scanned documents as part of their contact records so that when viewing the user's Civicrm Contact record i can view the uploaded document. However I find that when viewing the contact record i cannot see the uploaded documents. Only the upload field is visible.

Does anyone know how this can be implemented in CiviCRM or am doing something wrong? I am using CiviCRM 4.6.15 with wordpress.

Thanks in advance for your comments.

# Answer
we did have some issue with uploading files to custom field since 4.6.5 and above

I did made a quick test against http://wp46.demo.civicrm.org which is running on civicrm version 4.6.18

And the issue got fixed so please try to upgrade to the latest version and then please test the same

thanks
> 1 votes

---
Tags: custom-fields, profile, contact-view
---


# Question
Title: Assign more than 100 contributions to a Batch
Is it possible to assign more than 100 contributions to a batch? We have a site with thousands of contributions so we want to make this job quicker. By default, you can only assign 10, 25, 50, 100 contributions to a batch.

Screenshot from /civicrm/batchtransaction?reset=1&bid=x

# Answer
> 1 votes
You add more than 100 transactions to a batch, but only up to 100 at a time. I had to do this when first implementing the batch processing - creating a batch of previous transactions.

I just wish that Civi would remember the number of entries selected when returning from applying.

# Answer
> 0 votes
I don't think so.

You can only select a maximum of 100, when you want to do a batch update. So I think the same restrictions would apply universally on batches.

---
Tags: civicontribute, batches
---


title: Is it possible to run CiviCRM on HHVM

text:
# Question
Title: Is it possible to run CiviCRM on HHVM
We use HHVM rather than PHP-FPM on Nginx because it is way faster and creates far less load per visitor. HHVM is incompatible with certain PHP that PHP-FPM (PHP 5.x) doesn't have a problem with, so apps sometimes need edits to make them work.

In our case, we use Civi inside WordPress. WordPress seems to work fine in HHVM, as does our testing with Drupal so far.

I can't find any references to CiviCRM's compatibility with HHVM.

Has anyone tried it? Gotten it working? Should we give up?

# Answer
> 2 votes
I have tested this and have duplicated the WSOD error. The error I get in the hhvm log is `Fatal error: Cannot access private property Civi\\Core\\Transaction\\Frame::$state` As I am not that familar with HHVM I cannot take it much further.

Jeremy, do you get the same issue with Drupal and CiviCRM?

I have been satisfied with PHP-FPM performance, so while I hate to give things up, that may be the quickest path to getting this to work.

# Answer
> 0 votes
I was able to fix this by editing the file at `wp-content/plugins/civicrm/civicrm/Civi/Core/Transaction/Frame.php` and commenting out the `assert` calls that reference `$this->state`.

---
Tags: wordpress
---


# Question
Title: Access denied with viewing group contacts
I have a drupal 7 civicrm site just upgraded to 4.7.8 and I am user 1 for drupal and civicrm.

I have two instances where I cannot get past access denied

contacts/manage groups/select group and then when I press to see contacts it says access denied.

The same happens when I go to draft email and want to view the draft email.

I have a couple of other sites and this is not happening. These two use the same theme however so I think it is something theme related (possibly module therefore). I have disabled the theme and it did not resolve. But When in site maintenance node instead of access denied I get the site in maintenance mode page.

I'm not a developer so am not quite sure where to start in trouble shooting this. My permission credential is not being passed from page to page but I'm not sure why....

If anyone has any thoughts on where to start with this that would be great.

Thanks you. Caroline

# Answer
> 1 votes
Ah I found an answer in the old forum here https://forum.civicrm.org/index.php?topic=27010.0

---
Tags: permissions
---


# Question
Title: "no such field in civicrm_api3" after Upgrade from 4.6.4 to latest 4.7
I ran the database upgrade script and it showed me an error and didnt get finished..

since then I can't run the /civicrm/upgrade script and it always gives me the error:

CiviCRM\_API3\_Exception: DB Error: no such field in civicrm\_api3() (line 45 of /usr/share/drupal7/modules/civicrm/api/api.php)

please help.. I do NOT have a backup from my old database! Is there any other way to fix this?

thxx

# Answer
> 1 votes
I'm sorry for the troubles you have had (and I guess in the future you will backup before trying an upgrade).

It's very complicated to try to determine what completed, what didn't, and how to move forward from your situation. I'd generally recommend engaging the services of CiviCRM shop that has developer experience at this point.

An approach I would recommend in this situation is to create a new CiviCRM 4.7 site, then import the data from the 4.6 database. But you there is no standard script for doing this; hence the need for a CiviCRM developer.

---
Tags: upgrade, database, error
---


# Question
Title: Contribution emails not being sent - Direct Deposit/Pay Later
For online contributions, the only email that gets sent is when the contributor pays immediately (receipt). Thank you emails are not automatically sent and I cannot work out whether this is functioning as designed. When the direct deposit option is selected, no email is automatically sent out.

In addition there is a setting on the profile we use for contributions to notify when the form is submitted. This has not been working either.

After some research, I enabled the CiviContribute setting to automatically email invoices (enable tax and invoicing section) which made the email notification of profile submissions work for some reason, but not the invoice/receipts for pay later.

Any suggestions on how I can troubleshoot? CiviCRM v4.7.8 but this has been an issue since 4.7

Edit/Update: If I disable automatic email of invoices, no emails are sent unless pay now (including profile submission email). If I enable automatic email invoice I get a pdf invoice every time as well as a profile submission email. This is fine as a workaround but if anyone knows a way to get it to email without a pdf attachment, that would be better. I received intermittent emails without pdfs (one with an amount, one without amount) while I was testing a couple of hours ago, then the pdfs started arriving consistently, so I customised those as a way forward.

# Answer
> 0 votes
Looks like this bug but it should have been fixed in 4.7.4

---
Tags: wordpress, civicontribute, email, 4.7, receipts
---


# Question
Title: Submit Credit Card Membership (or Event Registration) Not showing in Admin
Not exactly sure what happened, but now the Submit Credit Card Membership option is not available in the Admin side of a Joomla install (v3.5.1). All seemed to be working fine, but then it disappeared. I tried recreating the Payment Processor and selecting it in the Contribution Page, but no luck. Then I opted to update to CiviCRM to 4.7.8 to see if that was the issues, still no luck. I am hoping it is just some sort of reset, otherwise our site is dead in the water with a conference coming up.

# Answer
> 2 votes
Looking at your issue: See CRM-15394

David Greenberg added a comment - 30/Sep/14 12:03 PM The back-office 'Submit Credit Contribution' feature is only available when the site has at least one configured payment processor of the type that allows credit card data to be entered within CiviCRM forms. This includes Paypal Pro, Auth.net and iATS. The link is hidden on the demo because the configured 'Test Processor' does not support this.

# Answer
> 0 votes
I am seeing the same thing in the Joomla Demo - I think you have found a bug. Please report it at https://issues.civicrm.org

Note this is only in Joomla, Drupal demo shows the link.

**Update:** Adding an authorize.net account on demo made the link appear. You could test your payment processor account on another instance to see if that's the problem.

---
Tags: joomla, payment-processor, admin
---


# Question
Title: How do I change the contribution type for a contribution that was made before 1/1/1996?
We're on Civi 4.6.17 and Drupal 7.

We have historic data that was imported from a previous system. There are some Contributions of type Member Dues that I want to change to a different Contribution Type - \[Organization Name\] Contribution - because the Contribution was misclassified when originally entered or imported.

But, the contribution was made before 1/1/1996. When I Edit the Contribution type a message pops up to "Please enter a date between 01/01/1996 and 12/31/2026".

Is the only way around this to go in to the back-end MySQL table for Contributions and change the type?

# Answer
> 1 votes
Date Preferences at civicrm/admin/setting/preferences/date?reset=1 can be edited so the 'offset' is greater than 20 (years)

SO you can edit Date for activities (including contributions: receive, receipt, cancel. membership: join, start, renew. case: start, end.) and set it to have years going back further than 1996 (ie 20 years)

---
Tags: civicontribute, civimember, contributions, date-preferences
---


# Question
Title: Looking for CiviSMS extension. New version?
I'm trying to install CiviSMS on a Drupal based CiviCRM install. I have Drupal 7.43 running CiviCRM 4.7.8 on a CentOS 7 platform.

# Answer
Did you have a look at the extensions directory on:

https://civicrm.org/extensions filter for SMS Select one and you'll find the download link

Note that both Clickatell and Twilio don't have a 4.7.x stable version listed yet - best to contact their authors to see where things are at.
> 1 votes

---
Tags: civisms
---


# Question
Title: Unsubscribe Token for Subscription Reminders
What's the best way to allow members to unsubscribe or opt out from Renewal Reminders?

Thanks!

# Answer
> 2 votes
Generally, there's not a way to opt-out of transactional emails, like receipts and reminders.

I found this in the documentation, which states

> Scheduled reminders are still sent to contacts who have opted out of bulk emails and those who have selected the privacy option Do not email.

It goes on to say

> If you want to exclude contacts who have opted out of bulk emails from a scheduled reminder you should:
>
> 1) Find all contacts who have not selected the privacy options Do not email or NO BULK EMAIL.
>
> 2) Create a smart group from the search results.
>
> 3) Select this smart group as the Recipients of the scheduled reminder.

---
Tags: civimember, scheduled-reminders
---


title: smart group change log criteria

text:
# Question
Title: smart group change log criteria
I am using CiviCRM 4.7.7 on Drupal 7. I want to send an e-mail to each contact added "Today". So I supposed to create a smart group with the search criteria "Added=Today" in the "Change Log" section. I suppose to create this smart group today, i.e the June 6th, 2016. Tomorrow the smart group criteria will be always the June 6th, 2016, and not the June 7th, 2016, as I would like. Can someone help me?

# Answer
> 1 votes
So, I might not be able to answer the question regarding the smart group criteria required to set the date always to 'today' (I had a look into this and confirmed your description that the criteria gets "translated" from 'today' into the date for today, and will remain that way afterwards).

However, if you're looking to send an email to each contact created in the system then you could look into using the scheduled reminders system for this. Under Entity you can select Contact \> Created date only, which might help with your scenario.

The downside to this though is that you'll need to be sending out the same message to each user (although you can use tokens to personalise this!).

---
Tags: email, smartgroups
---


# Question
Title: What is the status of CiviBooking for CiviCRM 4.6.x
Currently CiviBooking works for the LTS of 4.4.x. We are taking a look at this for 4.6.x so putting it up as a question to track progress

# Answer
> 10 votes
We are pleased to announce **CiviBooking 1.5** is finally released!

This version brings compatibility with:

* CiviCRM 4.5.x (not actively maintained)
* CiviCRM 4.6.x
* CiviCRM 4.7.x

It also contains a new permission structure for managing bookings.

Please feel free to get in touch if you have any question or encountered any issue. We will be actively maintaining the issue queue.

Updates:

* CiviCRM 4.6+ compatibility
* CiviBooking Permissions
* Improved consistency of permission structure for managing bookings
* Improved CiviCRM version compatibility
* Improved menu handling
* Fixed day view criteria
* Fixed additional charge modal problem

The new version of the extension can be downloaded here

# Answer
> 3 votes
At this point there is no available release for 4.6.x and needs some funders to get a upgraded release done according to this github issue

# Answer
> 3 votes
We have civibooking running on 4.6.x - we probably haven't tried all the features but can confirm that in going through the process of setting up a Booking and setting up Resource Types and Resources we didn't hit any issues, so this is just to encourage others to get in and test thoroughly and report back so Jamie and his team get some clearer idea of what hurdles there might be, and then we can all hopefully chip in.

# Answer
> 2 votes
There is a branch for CiviCRM 4.5 : `https://github.com/compucorp/civibooking/tree/civi4.5` that can be downloaded here.

There is no development on it since October 2014 but it seems to work on both 4.5 and 4.6. Or at least it doesn't crash. I have tested every link and made some simple booking but I don't know this extension that much so it's difficult for me to say if something is broken.

---
Tags: civibooking
---


# Question
Title: Group Membership Discounts using Group Based pricing
I am trying to add some functionality to membership pricing where the more people we can get to sign up at a time the bigger the discount they will get. So for instance:

1 - 4 members, $110 each, No discount, $110 - $440 5 - 10 members, $93 each, 15% discount, $465 - $930 11 - 20 members, $82 each, 25% discount, $902 - $1,640 21 - 40 members, $71 each, 35% discount, $1,491 - $2,840 40+ members, $55 each, 50% discount, $2,251 & up

How would I go about adding this to the membership sign up page? I've installed and enabled the group-based pricing extension

To be clear it would only apply to new members (new signups). And they would need the ability to say how many memberships they want.

# Answer
You can use webform\_civicrm module - but it will be quite some config!

Something like:

* add a Drupal field - how many members would you like to sign up?
* make as as many contacts in the civicrm tab as you need (you may need to bump up a parameter in webform\_civicrm code) - you can make one (add all the fields you want) then in the webform tab -\> clone
* use conditionals to show the correct number of contacts
* make sure you have relationship to primary contact (something like Member sign-up by)
* make sure your membership type filters down to inherit by relationship
* the monies... will be the default $ in your Membership Type config - however - you can add your own contribution field in webform and use conditionals (or jQuery to get the grand total $ right - based on the # of members field the user selected

Good luck setting that up! Please do report back!
> 1 votes

---
Tags: drupal, civimember
---


# Question
Title: Cannot add or update a child row: a foreign key constraint fails
I am using CiviCRM(4.6.10) with Drupal (7.38) together with the civicrm\_og\_sync module. Until now everything worked fine:

Everytime a drupal user was created automatically a civi contact was also created. Then I deleted a user account on drupal and the corresponding contact in civi (full deletion!).

Now when I try to create a new user in drupal I get the following error:

> `Datenbank-Errorcode: Cannot add or update a child row: a foreign key constraint fails (`civi_db`.`civicrm_log`, CONSTRAINT `FK_civicrm_log_modified_id` FOREIGN KEY (`modified_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE), 1452
>  Zusätzliche Details:
>  Array
>  (
>  [callback] => Array
>  (
>  [0] => CRM_Core_Error
>  [1] => handle
>  )
>  [code] => -3
>  [message] => DB Error: constraint violation
>  [mode] => 16
>  [debug_info] => INSERT INTO civicrm_log (entity_table , entity_id , data , modified_id , modified_date ) VALUES ('civicrm_contact' , 381 , 'civicrm_contact,381' , 374 , 20160111141559 ) [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`civi_db`.`civicrm_log`, CONSTRAINT `FK_civicrm_log_modified_id` FOREIGN KEY (`modified_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE)]
>  [type] => DB_Error
>  [user_info] => INSERT INTO civicrm_log (entity_table , entity_id , data , modified_id , modified_date ) VALUES ('civicrm_contact' , 381 , 'civicrm_contact,381' , 374 , 20160111141559 ) [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`civi_db`.`civicrm_log`, CONSTRAINT `FK_civicrm_log_modified_id` FOREIGN KEY (`modified_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE)]
>  [to_string] => [db_error: message="DB Error: constraint violation" code=-3 mode=callback callback=CRM_Core_Error::handle prefix="" info="INSERT INTO civicrm_log (entity_table , entity_id , data , modified_id , modified_date ) VALUES ('civicrm_contact' , 381 , 'civicrm_contact,381' , 374 , 20160111141559 ) [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`civi_db`.`civicrm_log`, CONSTRAINT `FK_civicrm_log_modified_id` FOREIGN KEY (`modified_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE)]"]
>  )`

In the end the drupal user is created but not the civi contact. I looked into the tables 'civicrm\_contact' and 'civicrm\_log' but couldn't find anything supicious - an id or modified\_id with number 381 did not exist. On the other hand I can still create a contact with the civi user-interface...

What can I do?

# Answer
It looks like civicrm is trying to record the change as being done with a different id than the contact that is trying to register (381 vs 374)

Are you sure you are properly anonymous? it might be that your site still think you are "someone else" (eg. the contact you deleted?).

Could you try creating a new account from a "clean" computer, or if you can't, try doing it with your computer, but from an anonymous session (each browser has a different way of doing that, in firefox, it's File-\>New Private window) and see if you experience the same issue?

and if you do, could you temporarily disable the og\_sync, to try to narrow down where the problem comes from?

X+
> 2 votes

# Answer
Logging out and back in solved the problem for me.

I had deleted a contact (probably associated contact with the logged in user). And then I began seeing this error.
> 0 votes

---
Tags: drupal, contacts, logs
---


# Question
Title: How can I allow opt-in subscription to specific groups with Webform CiviCRM?
I'd like to provide the option for users to subscribe to one of two CiviCRM Mailing List groups when submitting a Webform.

From the CiviCRM docs I can see how to use a CiviCRM-integrated Webform to add contacts to specific groups when they submit the form OR allow users to select from *any* of the groups in CiviCRM via the "User Select" option.

Is there a way to allow users to opt-in to a limited selection of existing groups, rather than allowing all groups?

# Answer
Once you have selected 'user select' for the groups in the CiviCRM section of the webform admin section, save and return to the 'components' tab (where all the webform fields are listed). Find your Groups field and edit it from the component list. If you change the list from Live to Static, you can then select which of your groups will appear as an option to the user.
> 8 votes

---
Tags: drupal, webform-civicrm
---


title: CiviCRM 4.7.4 breaks Ajax image upload

text:
# Question
Title: CiviCRM 4.7.4 breaks Ajax image upload
On Drupal 7.43 (fresh install) / CiviCRM 4.7.8 (same issue on 4.7.4)

After enabling the CiviCRM module the ajax upload of a custom image field added to drupal user accounts stopped working.

Additionally the ajax call fails also when trying to remove previously uploaded images.

The debug URL shows the generic error: "An unrecoverable error occurred. The uploaded file likely exceeded the maximum file size (80 MB) that this server supports"

Is this a known bug? Any way to resolve it?

Any help will be greatly appreciated. Thanks.

List of enabled Drupal modules:

CiviCRM CiviCRM (civicrm) 7.x-4.7.8 CiviCRM CiviCRM Theme (civicrmtheme) 7.x-4.7.8 Core Block (block) 7.43 Core Color (color) 7.43 Core Comment (comment) 7.43 Core Contextual links (contextual) 7.43 Core Dashboard (dashboard) 7.43 Core Database logging (dblog) 7.43 Core Field (field) 7.43 Core Field SQL storage (field\_sql\_storage) 7.43 Core Field UI (field\_ui) 7.43 Core File (file) 7.43 Core Filter (filter) 7.43 Core Help (help) 7.43 Core Image (image) 7.43 Core List (list) 7.43 Core Menu (menu) 7.43 Core Node (node) 7.43 Core Number (number) 7.43 Core Options (options) 7.43 Core Path (path) 7.43 Core RDF (rdf) 7.43 Core Search (search) 7.43 Core Shortcut (shortcut) 7.43 Core System (system) 7.43 Core Taxonomy (taxonomy) 7.43 Core Text (text) 7.43 Core Toolbar (toolbar) 7.43 Core Update manager (update) 7.43 Core User (user) 7.43

# Answer
> 1 votes
It looks like this was a regression caused by https://issues.civicrm.org/jira/browse/CRM-16513. Further information on the ticket.

---
Tags: drupal, 4.7, ajax
---


# Question
Title: "You are already subscribed to our newsletter" message
When someone who is already subscribed to our newsletter (i.e. they are a member of the relevant group) tries to subscribe to the newsletter again (for whatever reason, maybe the newsletters go to their Spam), nothing is happening that indicates that the person is already subscribed.

How can we make it so that in such a situation a message such as "You are already subscribed" would appear or, even better, the person gets redirected to a specified page?

# Answer
> 4 votes
CiviCRM does not have this feature built-in. You would need to write a custom extension to achieve this, probably using hook\_civicrm\_postProcess.

---
Tags: civimail, newsletter, subscribe
---


# Question
Title: Is is possible to import cases into Civi
A client has many cases in spreadsheets, and Civicase looks very suitable. I cannot see any facility to import cases into Civi via the UI. Is this possible? I guess the alternative is to import directly into the database. Any suggestions?

# Answer
As far as I know there is no Import Cases in the UI. So importing into the database would be the solution, but make sure you respect all the data models! You need to add data to civicrm\_case, civicrm\_case\_contact, probably civicrm\_case\_activity and civicrm\_activity and for the roles into civicrm\_relationship.
> 2 votes

# Answer
You might look at the API cvs Importer extension. https://civicrm.org/extensions/api-csv-import-gui

I've found the extension extremely helpful for creating all kinds of CiviCRM data from CSV formatted data.
> 2 votes

# Answer
I've just bulk created a whole load of cases from activities, taking the subject, clients etc from the activity. Creating cases through the API works fine. Can post the code if anyone's interested.
> 1 votes

# Answer
I've been working out the queries to do this for the past week or so for a client who is migrating from an old desktop database.

Here's the full list of tables involved:

**civicrm\_case**

**civicrm\_case\_contact** (to link each case to a contact id)

**civicrm\_activity** (to create the necessary activities for each case)

**civicrm\_case\_activity** (links activity to case id)

**civicrm\_activity\_contact** (multiple records for each activity)

**civicrm\_relationship** (relationships between case subject and assignees)

You can actually get away without filling in the relationships if this is purely historical data but it's only an extra query so you may as well fill it in.

I created a special case type for the data import and used the subject field to store details about the old cases during the SQL imports. I removed all required activities but one from this case type which simplified the import process.

When in doubt, just create test cases under a dummy contact and see what values are populated.

EDIT: I decided to write up the entire procedure on my website. You can find the details here - http://www.drewslair.com/2016/06/importing-case-data-civicase/
> -1 votes

---
Tags: civicase, 4.6
---


# Question
Title: Relationship type id stored in the wrong custom group column?
I made a custom group in a Relationship type. When I look back in MySQL table civicrm\_custom\_group I see that civicrm\_relationship\_type.id is stored in column civicrm\_custom\_group.extends\_entity\_column\_value .

I am trying to write query that lists all custom groups in order to write an initialisation script. When doing a JOIN ON involving civicrm\_custom\_group.extends\_entity\_column\_value, I discovered that is of type VARCHAR. I did not know that even with the MySQL CAST function it is impossible to use mixed types in a ON comparison.

Could it be bug that the id is stored in the wrong column? May be it should have been stored in column civicrm\_custom\_group.extends\_entity\_column\_id ? That column is correctly of type UNSIGNED INT(10)

# Answer
`civicrm_custom_group.extends_entity_column_value` stores more than just a number. You can have a custom group that extends a relationship type, but it can also be an activity type or a contact (sub-)type. If you extend a contact subtype, that field will contain the name of the subtype (not quite the same thing as the label btw), which will be in *words*.

The other thing is, that a custom group can extend *more than one* activity/relationship/contact subtype. How this is done, is by separating the values in `extends_entity_column_value` with the contents of `CRM_Core_DAO::VALUE_SEPARATOR` (ASCII SOH or 0x01), which isn't always visible when the data is shown to humans.

So, I have for `extends_entity_column_value` in one of my custom groups, `<SOH>School<SOH>Further_Education_Institution<SOH>`.

To unpack one of these kind of fields into an array, look at `CRM_Utils_Array::explodePadded`. (`implodePadded` being the reverse.) You could also match it using a regex- for example, this looks for a contact\_sub\_type field containing any of the subtypes School, Further Education Institution or Sixth Form College:

`AND contact_a.contact_sub_type REGEXP CONCAT('(^|', x'01', ')School|Further_Education_Institution|Sixth_Form_College($|', x'01', ')')`

**Edit**, for further info on where the IDs come from. `extends_entity_column_value` will contain SOH-separated:

* Numeric activity type IDs, if the custom group extends activities. Maybe null if it extends *all* activities. See also, `civicrm_option_group`'s `value` column when `option_group_id` is 2 (you're looking at options in the `activity_type` option group).
* Numeric relationship type IDs, if the custom group extends relationships. Maybe null if it extends *all* relationships. See also, `civicrm_relationship_type`'s `id` column.
* Contact subtype names, if the custom group extends a contact type. Maybe null if it extends *all* subtypes of a contact type. See also, `civicrm_contact_type`'s `name` column. (If you look in civicrm\_contact\_type, and any of your contact (sub-)types have spaces/punctuation in their names you'll see the difference between the name and the label. The name is for use by code, the label is for humans to see.)

Custom field groups can also extend things other than contacts, relationships and activities. Events, participants and contributions for example.
> 3 votes

---
Tags: custom-fields, relationships, issues
---


# Question
Title: How do I debug "Could not find valid value for ct" error message
Performed upgrade of Civi 4.4 to 4.6 alongside upgrade of Drupal from version 6 to version 7. The Drupal upgrade went fine, as did the CiviCRM upgrades (i.e. no errors were reported).

All dashboards and search functions in CiviCRM work fine, but as soon as I try and create anything (e.g. registering for an event, creating a new Individual, etc...) we get the error: "Could not find valid value for ct".

Searching forums showed this is an old error related to sessions, so checked over all the PHP.ini and Nginx settings to ensure cookies and other domain related settings were correct.

Can anyone point me in the right direction of where else to look?

\** EDIT \*** Additional error messages being shown after enabling debug:-

> Sorry but we are not able to provide this at the moment. We can't load the requested web page. This page requires cookies to be enabled in your browser settings. Please check this setting and enable cookies (if they are not enabled). Then try again. If this error persists, contact the site adminstrator for assistance.
> Site Administrators: This error may indicate that users are accessing this page using a domain or URL other than the configured Base URL. EXAMPLE: Base URL is http://example.org, but some users are accessing the page via http://www.example.org or a domain alias like http://myotherexample.org.
> Error type: Could not find a valid session key.

# Answer
OK, turns out this was due to erroneous entries in the Drupal settings.php file. The following entries were causing cookies to be missed by Civi:-

```
 ini_set('session.cookie_lifetime',  2000000);
 ini_set('session.gc_maxlifetime',   200000);

```

Others may also cause inconsistencies, such as:-

```
 ini_set('session.cache_expire',     200000);
 ini_set('session.cache_limiter',    'none');
 ini_set('session.cookie_lifetime',  2000000);
 ini_set('session.gc_maxlifetime',   200000);
 ini_set('session.save_handler',     'user');
 ini_set('session.use_cookies',      1);
 ini_set('session.use_only_cookies', 1);
 ini_set('session.use_trans_sid',    0);

```

Removing the entries from the drupal settings.php file, then closing the browser and re-establishing a new session has resolved the issue.

Essentially these settings within Drupal are conflicting with the PHP.ini settings that CiviCRM is seeing, which can lead to these erroneous types of session errors.
> 6 votes

---
Tags: drupal, upgrade, 4.6, drupal-6, 4.4
---


# Question
Title: Dropping thousands of records into a batch via SQL
I have imported (tens of) thousands of historic contributions to a site that uses Accounting Batches regularly. They were starting to bog down the batch assignment page so I thought I would simply create an administrative batch, drop them in via SQL directly as follows, and then be done with them.

```
insert into `civicrm_entity_batch` (entity_table,entity_id,batch_id)
select 'civicrm_financial_trxn',trxn.`id`,188 from `civicrm_financial_trxn` trxn
where trxn.`trxn_id` LIKE 'archive_%';

```

In the SQL above, I am inserting the string 'civicrm\_financial\_trxn' into the `entity_table` field, the id, and then the number 188 (which is the ID of the new batch I created). Also, all the transaction IDs for these archival records have been prepended with 'archive\_' (hence the `where` clause above to choose just these contributions).

This works for the most part (the transactions show up in the batch, and I can close it as I would expect), but there is a kicker. Now in any new batches, the bottom portion of the page where you typically assign transactions to the batch never stops "Processing":

The Drupal watchdog has a few notices:

```
Strict warning: Non-static method CRM_Batch_BAO_Batch::links() should not be
called statically in CRM_Batch_BAO_Batch::links() (line 280 of
/var/www/public_html/sites/all/modules/civicrm/CRM/Batch/BAO/Batch.php).

```

and

```
Notice: Undefined index: batch_type in
CRM_Batch_BAO_Batch::getBatchListSelector() (line 230 of
/var/www/public_html/sites/all/modules/civicrm/CRM/Batch/BAO/Batch.php).

```

Does anyone have an idea what this might mean? The archival imports were not intended to be fully integrated into the Financial/Accounting portion (they were batched and dealt with in a previous system) but were meant simply as informational background on contacts.

How can I troubleshoot/fix this?

# Answer
> 1 votes
Well this is not really an answer but it is a workaround. We've found that when creating the batch, if we specify the Payment Instrument (e.g. Credit Card) then it works. So we can get around this for now by doing separate batches for credit cards and checks.

---
Tags: mysql, sql, batches
---


# Question
Title: Menu bar missing on fresh CiviCRM on Wordpress
I did a fresh install of CiviCRM on Wordpress on WP Engine. It installed successfully, but the menu bar is missing so I can't navigate to any of the pages. I also have "system status: error." Here's a screenshot:

If I try to navigate to any of the front-end pages that are dependent on CiviCRM, I get the message "Sorry but we are not able to provide this at the moment. You do not have permission to access this page."

I'm running CiviCRM 4.7.8 on WordPress 4.4.3. My host is WP Engine.

EDIT: in my browser console I'm getting a lot of "can't find resource" type errors and it looks like it's trying to go to the wrong URL. But when I changed the Resource URL in the settings file to an absolute path, it broke the whole plugin and brought me to a white screen.

# Answer
The issue is the way WP Engine builds the user directory structure. We have a proposed patch in : https://github.com/civicrm/civicrm-core/pull/8494

Until that is merged, you can use the answer listed here: Word Press Install Missing civicrm.settings.php; dashboard unavailable; no menus

Make sure the `global $civicrm_setting;` precedes `$civicrm_setting['URL Preferences']['userFrameworkResourceURL'] = 'http://example.com/example-resource-url/';`
> 4 votes

---
Tags: wordpress, installation, menu
---


title: Show Event Custom Fields in Reports

text:
# Question
Title: Show Event Custom Fields in Reports
I have an event with custom fields that I use to collect information relevant to each participant's registration (for example, number of guests accompanying, seat preference, etc.). When I view the participants under the "Manage Events" view, it will show me the fee levels and quantities they selected, but not the custom fields. I have to click on each participant to view the content of the custom fields.

How can I generate a report that will show the custom fields? When I try to generate a custom report, the custom fields don't appear as columns I can select.

# Answer
> 3 votes
First thought: go into the config for your custom fields and check the box that says 'Searchable'!

That will then make that field available in all reports that pull in custom fields on specific entities.

If you still don't see it in the report you want to see it in - then installl Fuzion's Extended Reports extension!

---
Tags: civievent, civireport
---


# Question
Title: Declaring multiple maintainers for an extension?
Can I declare more than one author/maintainer in an extension's info.xml file? Maintenance of one of our public extensions fell to me a while ago as the other dev who wrote it left, but I don't want to remove his name.

# Answer
The real answer is no :-(

I just recently added two names between the author tags in the info.xml for a new extension - looks ok on Github!

Not sure if the CiviCRM automated listing will choke on it...
> 0 votes

---
Tags: extension
---


# Question
Title: Are there other types of labels that can be created other than the mailing labels?
How do I create labels other than the mailing labels? I'd like to be able to simply print off name (and maybe position) labels. All I can find is the basic mailing label and I don't want to change the address settings, I still need that feature as well. Is it possible to create my own label? I am on wordpress. It would be great not to have to use another program. Whenever I try to remove tokens in the address settings, the pdf comes up blank....

# Answer
I just tested the same against wordpress and civicrm 4.7 demo

Their is an option called Name Badge - I guess that is what you are looking for

Go To Administer -\> Communications -\> Label Format

Then Add New Labal and give your setting - Sheet Size to envelope #9 (depends)

Once you have created Label format you should see that you have created an name Badge - Now Find contact - select about 50 records and in the actions you will see "Mailing Label - print"

In the next step select your Name badge format and print to PDF - you should get all the address as excepted else change setting

Also look for http://wpmaster.demo.civicrm.org i have created some Examples check before it gets refreshed

Refer to the link for more details https://book.civicrm.org/user/current/events/event-badges/

If you have any issues please let me know so i will post some screen shots - I guess this helps !!!
> 2 votes

---
Tags: address-labels
---


# Question
Title: "No records of type '' found" error - shortcode in WordPress page to edit profile
Help - updating profile forms from the front-end has broken over the last few updates. I have the following shortcode used on a Wordpress page:

```
[civicrm component="profile" gid="14" mode="edit" hijack="0"]

```

Upon viewing the page, I get the ""No records of type '' found" error:

If the shortcode is set to "view", it displays fine.

This occurs with me logged in with admin privileges.

Ideas?

# Answer
Doh! Not sure if this is what others found, but I'm ashamed to say the error message:

> "No records of type '' found."

is shown when none of the fields in the Custom Data set are set to "Display in table" (!)
> 1 votes

---
Tags: wordpress, profile
---