1
0
Fork 0
web-jbeyerstedt/site/templates/webdesign.php

42 lines
1.2 KiB
PHP

<?php
// -------------------------------------------
// kirby template FOR jannikbeyerstedt.de
// copyright: Jannik Beyerstedt | https://jannikbeyerstedt.de
// license: http://www.gnu.org/licenses/gpl-3.0.txt GPLv3 License
// -------------------------------------------
$img = $page->featurette_img()->toFile();
snippet('base/html-head');
snippet('base/cont-header');
?>
<main class="section webdesign">
<div class="container">
<div class="row featurette">
<div class="col-sm-9 col-12">
<h2 class="featurette-heading"><?php echo $page->featurette_headline()->html() ?></h2>
<p class="lead"><?php echo $page->featurette_text()->kirbytextinline() ?></p>
</div>
<div class="col-sm-3 col-12">
<?php if ($img = $page->featurette_img()->toFile()) {
$imgurl = $img->url();
$srcset = $img->srcset([
'1x' => ['width'=>235, 'quality'=>70],
'2x' => ['width'=>235*2, 'quality'=>70]
]);
echo '<img src="'.$imgurl.'" class="img-fluid rounded" alt="Portrait" srcset="'.$srcset.'" />';
}?>
</div>
</div>
<?php echo $page->text()->kirbytext(); ?>
</div>
</main>
<?php snippet('base/cont-footer') ?>
<?php snippet('base/html-end', []) ?>