function theme_sooperthemes_gridstack_formatter in Sooperthemes GridStack 7
Implements theme callback function.
1 theme call to theme_sooperthemes_gridstack_formatter()
File
- ./
sooperthemes_gridstack.module, line 185 - Code for the SooperThemes GridStack feature.
Code
function theme_sooperthemes_gridstack_formatter($variables) {
$output = '<div class="sooperthemes-gridstack__img" style="background-image: url(' . $variables['image_url'] . ')"></div>';
if (isset($variables['path']['path'])) {
$path = $variables['path']['path'];
$options = isset($variables['path']['options']) ? $variables['path']['options'] : array();
// When displaying an image inside a link, the html option must be TRUE.
$options['html'] = TRUE;
$output = l($output, $path, $options);
}
return $output;
}