field_slideshow.tpl.php in Field Slideshow 7
Same filename and directory in other branches
Template file for field_slideshow
1 theme call to field_slideshow.tpl.php
- field_slideshow_field_formatter_view in ./
field_slideshow.module - Implements hook_field_formatter_view().
File
field_slideshow.tpl.phpView source
<?php
/**
* @file
* Template file for field_slideshow
*
*
*/
// Should fix issue #1502772
// @todo: find a nicer way to fix this
if (!isset($controls_position)) {
$controls_position = "after";
}
if (!isset($pager_position)) {
$pager_position = "after";
}
?>
<div id="field-slideshow-<?php
print $slideshow_id;
?>-wrapper" class="field-slideshow-wrapper">
<?php
if ($controls_position == "before") {
print render($controls);
}
?>
<?php
if ($pager_position == "before") {
print render($pager);
}
?>
<?php
if (isset($breakpoints) && isset($breakpoints['mapping']) && !empty($breakpoints['mapping'])) {
$style = 'height:' . $slides_max_height . 'px';
}
else {
$style = 'width:' . $slides_max_width . 'px; height:' . $slides_max_height . 'px';
}
?>
<div class="<?php
print $classes;
?>" style="<?php
print $style;
?>">
<?php
foreach ($items as $num => $item) {
?>
<div class="<?php
print $item['classes'];
?>"<?php
if ($num) {
?> style="display:none;"<?php
}
?>>
<?php
print empty($item['image']) ? render($item['rendered_entity']) : $item['image'];
?>
<?php
if (isset($item['caption']) && $item['caption'] != '') {
?>
<div class="field-slideshow-caption">
<span class="field-slideshow-caption-text"><?php
print $item['caption'];
?></span>
</div>
<?php
}
?>
</div>
<?php
}
?>
</div>
<?php
if ($controls_position != "before") {
print render($controls);
}
?>
<?php
if ($pager_position != "before") {
print render($pager);
}
?>
</div>