function social_profile_preprocess_input in Open Social 8.3
Same name and namespace in other branches
- 8.9 modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 8.4 modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 8.5 modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 8.6 modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 8.7 modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 8.8 modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 10.3.x modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 10.0.x modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 10.1.x modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
- 10.2.x modules/social_features/social_profile/social_profile.module \social_profile_preprocess_input()
Implements hook_preprocess_input().
File
- modules/
social_features/ social_profile/ social_profile.module, line 263 - The Social profile module.
Code
function social_profile_preprocess_input(&$variables) {
// Edit the profile tag displays to show the hierarchy to users.
// Only do this if it starts with a - to indicate it's a child.
if (!empty($variables['element']['#parents']) && $variables['element']['#parents'][0] === 'profile_tag' && substr($variables['element']['#title'], 0, 1) === '-') {
$variables['element']['#attributes']['class'][] = 'checkboxes--nested__child';
}
}