Fix image field access
This commit is contained in:
parent
2ff0db4906
commit
0cdefb0fe1
3 changed files with 4 additions and 4 deletions
|
@ -22,7 +22,7 @@ snippet('base/cont-header');
|
|||
<?php $i=0; foreach($children as $c) : $i++; ?>
|
||||
<div class="col-sm-6 col-lg-3"><div class="card">
|
||||
<a href="<?php echo $c->url(); ?>">
|
||||
<?php if ($img = $c->images()->find($c->exrpt_img())) {
|
||||
<?php if ($img = $c->exrpt_img()->toFile()) {
|
||||
$imgurl = $img->url();
|
||||
$srcset = $img->srcset([
|
||||
'1x' => ['width'=>400, 'quality'=>70],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue