You are here

function social_tagging_to_machine_name in Open Social 10.3.x

Same name and namespace in other branches
  1. 8.9 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  2. 8 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  3. 8.2 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  4. 8.3 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  5. 8.4 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  6. 8.5 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  7. 8.6 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  8. 8.7 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  9. 8.8 modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  10. 10.0.x modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  11. 10.1.x modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()
  12. 10.2.x modules/social_features/social_tagging/social_tagging.module \social_tagging_to_machine_name()

Main term names to machine name for on node edit / validate.

Parameters

string $text: A node.

Return value

mixed|string A machine name so it can be used pogrammatically.

8 calls to social_tagging_to_machine_name()
SocialFollowTagLazyBuilder::lazyBuild in modules/social_features/social_follow_taxonomy/modules/social_follow_tag/src/SocialFollowTagLazyBuilder.php
Returns tags for lazy builder.
SocialTaggingOverrides::loadOverrides in modules/social_features/social_tagging/src/SocialTaggingOverrides.php
Returns config overrides.
SocialTaggingService::buildHierarchy in modules/social_features/social_tagging/src/SocialTaggingService.php
Returns a multilevel tree.
social_follow_landing_page_field_widget_entity_reference_paragraphs_form_alter in modules/social_features/social_follow_taxonomy/modules/social_follow_landing_page/social_follow_landing_page.module
Implements hook_field_widget_WIDGET_TYPE_form_alter().
social_follow_landing_page_preprocess_paragraph in modules/social_features/social_follow_taxonomy/modules/social_follow_landing_page/social_follow_landing_page.module
Implements hook_preprocess_HOOK().

... See full list

File

modules/social_features/social_tagging/social_tagging.module, line 551
Contains social_tagging.module.

Code

function social_tagging_to_machine_name($text) {
  $text = strtolower($text);
  $text = str_replace(' ', '', $text);
  return $text;
}