Uitgelicht podcast [#00028]

This commit is contained in:
NH Gooi
2024-09-12 14:06:28 +02:00
parent 5ebf7f20be
commit 6d91e1d3ca
3 changed files with 26 additions and 12 deletions

View File

@@ -170,12 +170,28 @@
@if ($podcast)
<?php $url = route('gemist.fragment') . $podcast->url; ?>
<h4 class="box_header"><span>Uitgelicht</span></h4>
<h4 class="box_header"><span>Uitgelicht fragment</span></h4>
<div class="box featured">
<div class="row">
<div class="col-12 col-md-6">
<a href="{{$url}}" title="{{$podcast->title}}">
<img src="{{$podcast->image && $podcast->image->url ? $imgBase . $podcast->image->url : '/images/noimage.png'}}"/>
<img src="{{($hasImage = $podcast->image && $podcast->image->url) ? $imgBase . $podcast->image->url : '/images/noimage.png'}}"/>
<div class="sentence">
<?php
$sentence = [];
if ($hasImage) {
$sentence[] = '<span class="text">' . $podcast->image->title . '</span>';
} elseif (isset($podcast->image->title) && $podcast->image->title) {
$sentence[] = '<span class="text">' . $podcast->image->title . '</span>';
}
if (isset($podcast->image->author) && $podcast->image->author) {
$sentence[] = '<span class="author">' . $podcast->image->author . '</span>';
}
$sentence = join('<span class="separator">|</span>', $sentence);
?>
{!!$sentence!!}
</div>
</a>
</div>
<div class="col-12 col-md-6">