<?php
$header_options_arr = get_option('archive_auction_text');

$get_auctions_from_post = get_the_terms($post->ID, 'auction_number');
$get_current_auction    = get_term($get_auctions_from_post[0]->term_id);

$auction_full_name     = get_field('auction_full_name', $get_current_auction->taxonomy . '_' . $get_current_auction->term_id);
$auction_start_date    = get_field('auction_start_date', $get_current_auction->taxonomy . '_' . $get_current_auction->term_id);
$auction_subtitle      = get_field('auction_subtitle', $get_current_auction->taxonomy . '_' . $get_current_auction->term_id);
?>
        <script type="text/javascript">
            var eventDate = '<?= $auction_start_date ?>';
            var currentAuctionNumber = <?= $get_current_auction->name ?>;

            jQuery(document).ready(function() {
                init();
                changeDateFormat(eventDate);
            });
        </script>

    <div class="header__auction with_featured_img">
        <div class="header__auction_bkg" style="background-image:url(<?= $header_options_arr['image'] ?>)" ></div>
        <div class="header__auction_overlay"></div>
        <div class="header__auction_info_row row">
            <h2 class="header__auction_title text_center"><?= $auction_subtitle . ' ' . $get_current_auction->name?></h2>
            <p class="header__auction_date text_center"></p>
        </div><!-- .auction_info_row-->
    </div>