File: //proc/thread-self/root/var/www/html/WPSassoon/wp-content/themes/sassoon/page-transactions.php
<?php /* Template Name: transactions Page */
get_header();
?>
<!-- <section class="inner-banner about-banner">
<div class="container custom-container">
<div class="contents">
<div class="subtitle">
Tombstones
</div>
<div class="main-title">
Fueling your success with knowledge and innovation.
</div>
<div class="content">
Our programs are fully integrated to support the growth and success of companies
</div>
</div>
</div>
</section> -->
<section class="inner-banner about-banner">
<div class="container custom-container align-center">
<div class="contents">
<div class="main-title">Recent Transactions</div>
</div>
</div>
</section>
<!-- <section class="transaction-boxes">
<div class="container custom-container">
<div id="deals-container" data-page="1" data-perpage="6">
</div>
</div>
</section> -->
<section class="carousel-wrap">
<div class="container custom-container">
<?php
$query = new WP_Query([
'post_type' => 'deal',
'posts_per_page' => -1
]);
if ($query->have_posts()) :
echo '<div class="tom-slider">';
while ($query->have_posts()) :
$query->the_post();
// Get custom fields (ACF or standard post_meta)
$buyer_name = get_post_meta(get_the_ID(), '_buyer_name', true);
$buyer_logo = get_post_meta(get_the_ID(), '_buyer_logo', true);
$seller_name = get_post_meta(get_the_ID(), '_seller_name', true);
$seller_logo = get_post_meta(get_the_ID(), '_seller_logo', true);
// Taxonomy (deal_category)
$terms = wp_get_post_terms(get_the_ID(), 'deal_category');
$category_name = !empty($terms) ? esc_html($terms[0]->name) : '';
// Fallback logos if missing
$buyer_logo_url = !empty($buyer_logo) ? esc_url($buyer_logo) : get_template_directory_uri() . '/img/default-buyer.svg';
$seller_logo_url = !empty($seller_logo) ? esc_url($seller_logo) : get_template_directory_uri() . '/img/default-seller.svg';
?>
<div>
<div class="box-wrap">
<div class="box-col-wrap">
<div class="tag">Buyer</div>
<div class="img-wrap">
<img src="<?php echo $buyer_logo_url; ?>" alt="<?php echo esc_attr($buyer_name); ?>">
</div>
<?php if (!empty($buyer_name)) : ?>
<!-- <div class="buyer-name"><?php echo esc_html($buyer_name); ?></div> -->
<?php endif; ?>
</div>
<div class="box-center">
<div class="txt">HAS BEEN ACQUIRED BY</div>
<?php if (!empty($category_name)) : ?>
<!-- <div class="category"><?php echo esc_html($category_name); ?></div> -->
<?php endif; ?>
</div>
<div class="box-col-wrap sec">
<div class="tag">Seller</div>
<div class="img-wrap">
<img src="<?php echo $seller_logo_url; ?>" alt="<?php echo esc_attr($seller_name); ?>">
</div>
<?php if (!empty($seller_name)) : ?>
<!-- <div class="seller-name"><?php echo esc_html($seller_name); ?></div> -->
<?php endif; ?>
</div>
</div>
</div>
<?php
endwhile;
echo '</div>'; // .tom-slider
wp_reset_postdata();
endif;
?>
</div>
</section>
<!-- sub-footer -->
<div class="sub-footer">
<div class="container custom-container d-flex flex-column align-items-start">
<h4 class="title">Thinking about your next move? Let's talk. </h4>
<p class="desc">If you're contemplating a sale, seeking growth capital, or just starting to explore your options, we're here to guide you forward. Reach out for a complimentary consultation.
</p>
<a href="" class="round-btn"><span><img src="<?php echo get_template_directory_uri(); ?>/img/svg/icon_call.svg" alt=""></span>Contact Us</a>
</div>
</div>
<?php get_footer(); ?>
<script>
$(document).ready(function () {
$('.tom-slider').slick({
slidesToShow: 4,
slidesToScroll: 1,
autoplay: false,
autoplaySpeed: 3000,
dots: false,
arrows: true,
prevArrow: '<button class="slick-prev"><svg width="33" height="33" viewBox="0 0 33 33" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M16.25 0C7.29625 0 0 7.29625 0 16.25C0 25.2038 7.29625 32.5 16.25 32.5C25.2038 32.5 32.5 25.2038 32.5 16.25C32.5 7.29625 25.2038 0 16.25 0ZM19.1588 21.125C19.63 21.5963 19.63 22.3762 19.1588 22.8475C18.915 23.0912 18.6063 23.205 18.2975 23.205C17.9888 23.205 17.68 23.0912 17.4362 22.8475L11.7 17.1112C11.2287 16.64 11.2287 15.86 11.7 15.3888L17.4362 9.6525C17.9075 9.18125 18.6875 9.18125 19.1588 9.6525C19.63 10.1237 19.63 10.9038 19.1588 11.375L14.2837 16.25L19.1588 21.125Z" fill="#BBBDBE"/></svg></button>',
nextArrow: '<button class="slick-next"><svg width="33" height="33" viewBox="0 0 33 33" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M16.25 0C7.29625 0 0 7.29625 0 16.25C0 25.2038 7.29625 32.5 16.25 32.5C25.2038 32.5 32.5 25.2038 32.5 16.25C32.5 7.29625 25.2038 0 16.25 0ZM19.1588 21.125C19.63 21.5963 19.63 22.3762 19.1588 22.8475C18.915 23.0912 18.6063 23.205 18.2975 23.205C17.9888 23.205 17.68 23.0912 17.4362 22.8475L11.7 17.1112C11.2287 16.64 11.2287 15.86 11.7 15.3888L17.4362 9.6525C17.9075 9.18125 18.6875 9.18125 19.1588 9.6525C19.63 10.1237 19.63 10.9038 19.1588 11.375L14.2837 16.25L19.1588 21.125Z" fill="#BBBDBE"/></svg></button>',
responsive: [
{
breakpoint: 1199,
settings: {
slidesToShow: 3
}
},
{
breakpoint: 767,
settings: {
slidesToShow: 2
}
},
{
breakpoint: 479,
settings: {
slidesToShow: 1
}
}
]
});
});
</script>