You are here

function entity_background_get_plugin_from_group_name in Entity background 7

Helper function used to get plugin name from the field group name. For example, group_bd_image to image.

Parameters

string $group_name: The whole group name containing group prefix.

Return value

string A group plugin name without group prefix.

3 calls to entity_background_get_plugin_from_group_name()
EntityBackgroundAPITest::testEntityBackgroundTestAPI in tests/entity_background.test
Test basic APIs.
entity_background_field_widget_form_alter in ./entity_background.module
Implements hook_field_widget_form_alter().
entity_background_find_background_plugin in ./entity_background.module
Find out if the plugin for the specified entity exists and return it.

File

./entity_background.module, line 148
Module file entity background.

Code

function entity_background_get_plugin_from_group_name($group_name) {
  return str_replace(EB_FG_PREFIX, '', $group_name);
}