Пример #1
0
<?php

get_header();
$hero_id = 2;
$hero_content = posts::getPostContent($hero_id);
$hero_bg = wp_get_attachment_image_url(get_post_thumbnail_id($hero_id), 'full');
$hero_bg = $hero_bg ? 'background-image: url(' . $hero_bg . ');' : '';
?>

<div style="<?php 
echo $hero_bg;
?>
" class="container-fluid hero-wrap">
	<div class="container">
		<div class="row">
			<div class="col-md-12">
				<?php 
echo $hero_content;
?>
			</div>
		</div>
	</div>
</div>

<?php 
$services = cats::getCat(4);
if ($services) {
    $services_posts = posts::getPosts($services['term_id']);
    ?>

	<?php