Пример #1
0
//all svgs
?>

<a class="skip-link screen-reader-text" href="#content"><?php 
_e('Skip to content', 'tst');
?>
</a>
<div class="mdl-layout mdl-js-layout mdl-layout--fixed-header mdl-layout--overlay-drawer-button">

<header class="mdl-layout__header ontop">
	<div class="mdl-layout__header-row">
		<noscript><a href="<?php 
echo home_url('sitemap');
?>
" class="nojs-menu"><?php 
echo tst_material_icon('menu');
?>
</a></noscript>
		<!-- Crumb -->
		<span class="mdl-layout-title"><?php 
echo tst_breadcrumbs();
?>
</span>
		
		<!-- Logo -->
		<span class="site-logo"><a href="<?php 
echo home_url();
?>
"><?php 
tst_site_logo('small');
?>
Пример #2
0
    echo apply_filters('leyka_the_content', leyka_pf_get_pm_description());
    ?>
	</div>
	
</form>
</div>
</div>
<?php 
}
//add agree modal to footer
add_action('wp_footer', function () {
    ?>
<div id="leyka-agree-text" class="leyka-oferta-text leyka-custom-modal">
	<div class="leyka-modal-close">		
			<?php 
    echo tst_material_icon('close');
    ?>
		
	</div>
	<div class="leyka-oferta-text-frame">
		<div class="leyka-oferta-text-flow">
			<?php 
    echo apply_filters('leyka_terms_of_service_text', leyka_options()->opt('terms_of_service_text'));
    ?>
		</div>
	</div>
</div>
<?php 
});
leyka_pf_footer();
?>
Пример #3
0
function tst_event_card($event)
{
    $img_id = get_post_thumbnail_id($event->ID);
    $img = wp_get_attachment_image_src($img_id, 'post-thumbnail');
    $date = get_post_meta($event->ID, 'event_date', true);
    $time = get_post_meta($event->ID, 'event_time', true);
    $location = get_post_meta($event->ID, 'event_location', true);
    $addr = get_post_meta($event->ID, 'event_address', true);
    $pl = get_permalink($event);
    $e = !empty($event->post_excerpt) ? $event->post_excerpt : wp_trim_words(strip_shortcodes($event->post_content), 20);
    ob_start();
    ?>
	
	<div class="mdl-card__media" style="background-image: url(<?php 
    echo isset($img[0]) ? $img[0] : '';
    ?>
);?>">
		
	</div>
	
	<div class="event-content-frame">
		<div class="mdl-card__title">
			<h4 class="mdl-card__title-text"><a href="<?php 
    echo $pl;
    ?>
"><?php 
    echo get_the_title($event);
    ?>
</a></h4>
		</div>	
		<div class="event-meta">
			<div class="pictured-card-item event-date">
				<div class="em-icon pci-img"><?php 
    echo tst_material_icon('schedule');
    ?>
</div>				
				<div class="em-content pci-content">
					<h5 class="mdl-typography--body-1"><?php 
    echo date('d.m.Y', $date);
    ?>
</h5>
					<p class="mdl-typography--caption"><?php 
    echo apply_filters('tst_the_title', $time);
    ?>
</p>
					<?php 
    if (tst_is_future_event($date)) {
        tst_add_to_calendar_link_in_modal($event, true, 'in-modal-add-tip');
    }
    ?>
				</div>
			</div>
			<div class="pictured-card-item event-location">
				<div class="em-icon pci-img"><?php 
    echo tst_material_icon('room');
    ?>
</div>				
				<div class="em-content pci-content">
					<h5 class="mdl-typography--body-1"><?php 
    echo apply_filters('tst_the_title', $location);
    ?>
</h5>
					<p class="mdl-typography--caption"><?php 
    echo apply_filters('tst_the_title', $addr);
    ?>
</p>
				</div>
			</div>	
		</div>	
		<div class="mdl-card__supporting-text"><?php 
    echo apply_filters('tst_the_title', $e);
    ?>
</div>
	</div>	
	
	<div class="mdl-card__actions mdl-card--border">		
		<a href="<?php 
    echo $pl;
    ?>
" class="mdl-button mdl-button--colored mdl-js-button mdl-js-ripple-effect"><?php 
    _e('Participate', 'tst');
    ?>
</a>
	</div>
	
<?php 
    $out = ob_get_contents();
    ob_end_clean();
    return $out;
}