示例#1
0
文件: home.php 项目: Ashkas/CAT
					<?php 
        if ($tagline) {
            ?>
						<h1 class="banner_tagline big_margin_bottom"><?php 
            echo $tagline;
            ?>
</h1>
					<?php 
        }
        ?>
					<ul class="cta_buttons">
						<?php 
        $counter = 1;
        while (has_sub_field('homepage_banner_cta', 'option')) {
            if ($counter == 1) {
                $link = get_cta_link(get_sub_field('title'), get_sub_field('url'), 'big_button');
            } else {
                $link = get_cta_link_alt(get_sub_field('title'), get_sub_field('url'), 'big_button');
            }
            if ($link) {
                ?>
							    <li><?php 
                echo $link;
                ?>
</li>
							<?php 
            }
            $counter++;
        }
        ?>
					</ul><!--#menu-secondary-nav-->
示例#2
0
文件: header.php 项目: Ashkas/CAT
<?php

//Variables
$home_url = home_url();
$template_directory = get_bloginfo('template_directory');
// ACF Variables
if (function_exists('get_field')) {
    $get_header_logo = get_field('logo', 'option');
    $header_logo = wp_get_attachment_image_src($get_header_logo, 'full');
    $phone_number = get_field('site_phone_number', 'option');
    if (get_field('header_cta', 'option')) {
        while (has_sub_field('header_cta', 'option')) {
            $cta_button = get_cta_link(get_sub_field('header_cta_title'), get_sub_field('header_cta_url'));
        }
    }
}
?>

<!-- Google Tag Manager -->
	<noscript><iframe src="//www.googletagmanager.com/ns.html?id=GTM-TPSBPL"
	height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
	<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
	new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
	j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
	'//www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
	})(window,document,'script','dataLayer','GTM-TPSBPL');</script>
<!-- End Google Tag Manager -->

<header class="header" role="banner" id="top">
	<div class="topbar">
		<div class="container">