function theme_social_media_links_platform in Social Media Links Block and Field 7
Theme function for a single platform element.
1 theme call to theme_social_media_links_platform()
- template_preprocess_social_media_links_platforms in ./
social_media_links.module - Preprocesses variables for social media links platforms.
File
- ./
social_media_links.module, line 631 - Functions for the Social Media Links module.
Code
function theme_social_media_links_platform(&$variables) {
$output = '';
$icon = theme_image(array(
'path' => $variables['icon_path'],
'alt' => $variables['icon_alt'],
'attributes' => array(),
));
$options = array();
$options['attributes'] = $variables['attributes'];
$options['html'] = TRUE;
$output .= l($icon, $variables['link'], $options);
if (!empty($variables['appearance']['show_name'])) {
if ($variables['appearance']['orientation'] == 'h') {
$output .= '<br />';
}
$title = check_plain($variables['attributes']['title']);
$output .= '<span>' . l($title, $variables['link'], $options) . '</span>';
}
return $output;
}