Sneak Peek: Early work on CiviCRM Blocks and CiviCRM Fields

Backdrop shares much of the deep integration with CiviCRM that Drupal 7 offers. This includes the ability to create dynamic views of CiviCRM content (e.g. filterable directories of contact info), the ability to sync membership status to a Backdrop role (e.g. members only content), and the power that Webform CiviCRM provides (e.g. forms that push and pull data from your contact database). That said, some of CiviCRM's core functionality is still a few steps removed. Contribution pages still don't play perfectly nicely with custom URLs when dealing with menus and blocks, for example, and event pages aren't well integrated into the main Backdrop site.

We're developing a few new CiviCRM-related modules for Backdrop CMS to help soften some of the edges between the systems. The modules will allow you to add CiviCRM pages (e.g. Contribution pages or Event registration pages) into blocks and fields. Here's an early overview, with some benefits in point form below.

CiviCRM Blocks

CiviCRM Blocks allows CiviCRM forms to be inserted into any Backdrop Layout. Some sample uses:

  • Insert a CiviCRM page into an entire sub-section of a website based on path.
  • Show a CiviCRM form for specific users based on role.
  • Include a CiviCRM form on a specific Layout built as a long-form scrolling page with other elements placed around the Layout's regions.

CiviCRM Fields

CiviCRM Fields allows CiviCRM forms to be inserted into any fieldable Backdrop Entity such as content/nodes, taxonomy/terms, Paragraph types, etc. Sample use cases:

  • More deeply integrate donation forms into the site in terms of URL structure, placement in site search results, etc.
  • Add a CiviCRM Event Registration field to your site's Event content type, so all calendar events show in the same calendar with an option to expose the registration form (as a form or as a button/link) as needed.
  • Allow insertion of CiviCRM forms while building and reordering page content with Paragraphs.
  • Hide the CiviCRM page from automatic display on content nodes or taxonomy terms, and pull it into any region of a Layout (built on the node/% or taxonomy/term/% contexts). This will function much like CiviCRM Blocks but in a more targeted way -- each node or term could pull in a specific CiviCRM page rather than a single page being designated across many pages.

Future Plans and Possibilities

  • Ability to specify on a CiviCRM Field whether to provide the option for Event Registrations or Contribution Pages or both. (e.g. for a field being added to an Event content type, you may not want to show the Contribution Page option)
  • Add other CiviCRM integrations? (Cases, Profiles, etc.)
  • Possibly the ability to specify "Add new" -- which would allow you to create and populate basic information from the Backdrop side rather than setting up an Event or Contribution Page first. This needs to be thought through a little more, but could be useful, for example, when using the CiviCRM field on an Event content type as a registration button. A CiviCRM event could be created with the title/date pulled from Backdrop, possibly details filled in from an Event Template in CiviCRM, and you have a one-stop shop to add events to your calendar, whether or not they have registration. Obviously this possibility needs much more thorough fleshing out.
  • Suggestions and collaboration are more than welcome -- development is still in an early stage.

Thanks to

  • Backdrop (and Drupal), CiviCRM (and specifically the core CiviCRM-Wordpress integration, from which the shortcode integration was an inspiration for this work).
Office: