function theme_skype_button in Skype 7
Theme function to render skype button.
1 theme call to theme_skype_button()
- skype_field_formatter_view in ./
skype.module - Implements hook_field_formatter_view().
File
- ./
skype.module, line 276
Code
function theme_skype_button($vars) {
$skype_id = $vars['skype_id'];
$settings = $vars['settings'];
$actions = array_filter($settings['actions']);
$skype_name = count($actions) > 1 ? 'dropdown' : array_shift($actions);
$unique_id = uniqid();
$output = '<div id="SkypeButton_' . $unique_id . '">
<script type="text/javascript">
Skype.ui({
"name": "' . $skype_name . '",
"element": "SkypeButton_' . $unique_id . '",
"participants": ["' . $skype_id . '"],
"imageColor": "' . $settings['image_color'] . '",
"imageSize": ' . $settings['image_size'] . '
});
</script>
</div>';
return $output;
}