HEX
Server: Apache/2.4.58 (Ubuntu)
System: Linux ubuntu-s-2vcpu-4gb-amd-sfo3-01 6.8.0-71-generic #71-Ubuntu SMP PREEMPT_DYNAMIC Tue Jul 22 16:52:38 UTC 2025 x86_64
User: root (0)
PHP: 8.2.30
Disabled: NONE
Upload Files
File: /var/www/mentalhealthsteps.com/wp-content/themes/mentalhealthworld/footer.php
 <!-- Footer Start-->
  <footer class="footer px-4">
    <div class="b-container">
      <div class="row row-cols-1 pt-5 px-0">
        <div class="footer-logo col-12 col-lg-3 mb-5 text-lg-start text-center">
          <!-- <img src="image/client-logo.png" alt="Footer Logo"> --> 
          <a href="<?php echo home_url(); ?>" class="logo-link">
              <span class="logo-span footer_logo_span">
                  <?php $footer_logo = get_field('footer_logo','option'); ?>
                     <img src="<?php echo esc_url($footer_logo['url']); ?>" alt="<?php echo esc_attr($footer_logo['alt']); ?>" />
                  <?php //the_field('footer_logo_text', 'option'); ?>
              </span>
          </a>
          <p class=""><?php the_field('footer_content', 'option'); ?>
          </p>
          <hr class="text-white">
          <p class="text-white">Download Apps On</p>
          <div class="app-div d-flex flex-column">
            <a href=""><img src="<?php echo bloginfo('template_directory'); ?>/image/play-store (1).png" alt=""></a>
            <a href=""><img src="<?php echo bloginfo('template_directory'); ?>/image/apple-store (1).png" alt=""></a>
          </div>

        </div>
        <div class="col-12 col-sm-6 col-md-4 col-lg-3 mb-3">
          <h4 class="text-secondary-color-2  mb-4">Contact</h4>
          <p class="text-white" style="font-weight: 600;"><?php the_field('address', 'option'); ?></p>
          <p><a class="text-white fw-bold text-decoration-none" href="mailto:<?php the_field('email', 'option'); ?>"><?php the_field('email', 'option'); ?></a></p>
          <p><a class="text-white fw-bold text-decoration-none" href="tel:<?php the_field('phone_no', 'option'); ?>">+<?php the_field('phone_text', 'option'); ?></a></p>
        </div>
        <div class="col-12 col-sm-6 col-md-4 col-lg-3 mb-3">
          <h4 class="text-secondary-color-2 mb-4">Quick Links</h4>
          <?php wp_nav_menu(array(
                    "theme_location" => "footer",
                    "menu" => "Footer Nav 1",
                    "menu_class" => "d-flex flex-column p-0 mb-5"
                )) ?>
          <!--<ul class="d-flex flex-column p-0">-->
          <!--  <li class="mb-2"><a href="#" class="links-secondary text-white">Home</a></li>-->
          <!--  <li class="mb-2"><a href="#" class="links-secondary text-white">About Us</a></li>-->
          <!--  <li class="mb-2"><a href="#" class="links-secondary text-white">Research</a></li>-->
          <!--  <li class="mb-2"><a href="#" class="links-secondary text-white">Funding</a></li>-->
          <!--  <li class="mb-2"><a href="#" class="links-secondary text-white">News & Events</a></li>-->
          <!--  <li class="mb-2"><a href="#" class="links-secondary text-white">Medication</a></li>-->
          <!--</ul>-->
          <a href="javascript:void(0);" class="footer-advertise-link contact-popup-link">Advertise with Us</a>
        </div>
        <div class="col-12 col-md-4 col-lg-3 mb-3 text-md-start text-center">
          <h4
            class="font-1 fw-bolder text-secondary-color-2 mb-4 justify-content-md-start justify-content-center align-items-center mt-md-0 mt-sm-4">
            Newsletter</h4>
          <p class="fw-bolder text-white">Get In Touch</p>
          <?php echo do_shortcode('[contact-form-7 id="4151d21" title="Newsletter" html_class="d-flex mb-3 flex-column w-100 gap-2 needs-validation"]'); ?>
          <!--<form class="d-flex mb-3 flex-column w-100 gap-2 needs-validation" novalidate>-->
          <!--  <input type="text" name="action" value="subscribe" hidden>-->
          <!--  <input type="email" name="email" class="form-control form-control-lg rounded-5"-->
          <!--    placeholder="Your email here" required>-->
          <!--  <div class="invalid-feedback text-white">-->
          <!--    Please provide a valid email format (e.g.,-->
          <!--    user@example.com).-->
          <!--  </div>-->
          <!--  <button type="submit" class="btn btn-block btn-secondary-solid submit_subscribe">Subscribe-->
          <!--    now</button>-->
          <!--</form>-->
          <div class="f-hr"></div>
          <div class="social-box d-flex justify-content-lg-start justify-content-center w-100">
              <?php
                  if( have_rows('social_media', 'option') ):
                   while( have_rows('social_media', 'option') ) : the_row(); ?>
            <a href="<?php the_sub_field('media_link'); ?>">
              <i class="fa-brands fa-<?php the_sub_field('media_class'); ?>"></i></a>
               <?php endwhile; endif; ?>
          </div>
        </div>

      </div>
      <div class="col-lg-12 mt-5">
                <?php echo do_shortcode('[alphabet_filter]'); ?>
            </div>
      <div class=" copy-right row justify-content-center py-4 mt-4 border-top">
        <p class=" text-center w-100 mb-0">Copyright &copy; <?php echo date('Y'); ?> <a href="<?php echo home_url(); ?>"
            class="links-secondary text-dark fw-bold">MentalHealthSteps.com</a> <?php the_field('copyright', 'option'); ?></p>
      </div>
    </div>
  </footer>
  <!-- #footer end -->




  


  <script>
    const today = new Date();
    const options = {
      timeZone: 'America/New_York',
      year: 'numeric',
      month: '2-digit',
      day: '2-digit',
      hour: '2-digit',
      minute: '2-digit',
      second: '2-digit',
      hour12: true
    };

    const usaTime = today.toLocaleString('en-US', options);
    document.getElementById("today").innerHTML = usaTime;
  </script>
 
  <!-- Popup -->
  <div id="contactOverlay"></div>
<div id="contactPopup">
  <button type="button" id="contactClose">×</button>
  <h2>Contact</h2>
        <?php
             if ( get_field('popup_form_shortcode','option') ) {
                echo do_shortcode( get_field('popup_form_shortcode','option') );
              }  
          ?>
  <!--<form>-->
  <!--  <label for="name">Name</label>-->
  <!--  <input type="text" id="name" placeholder="Name">-->

  <!--  <label for="email">Email</label>-->
  <!--  <input type="email" id="email" placeholder="Email Id">-->

  <!--  <label for="phone">Phone</label>-->
  <!--  <input type="text" id="phone" placeholder="Phone No">-->

  <!--  <label for="message">Message</label>-->
  <!--  <textarea id="message" placeholder="Message"></textarea>-->

  <!--  <button type="submit">Submit Now</button>-->
  <!--</form>-->

  <!-- Google Map -->
  <div  style="margin-top:15px;">
      <iframe src="<?php the_field('popup_form_map', 'option'); ?>" width="100%" height="300px" style="border:0;" allowfullscreen="" loading="lazy" referrerpolicy="no-referrer-when-downgrade"></iframe>
  </div>

  <div class="contact-details mt-3">
    <h3>Contact Details</h3>
    <p>Address: <?php the_field('address', 'option'); ?></p>
    <p>Need Support? <br> <?php the_field('phone_text', 'option'); ?> <br> <?php the_field('email', 'option'); ?></p>
  </div>
</div>



<script>
document.addEventListener("click", function(e) {
    var contactLink = e.target.closest(".contact-popup-link");
    var popup = document.getElementById("contactPopup");
    var overlay = document.getElementById("contactOverlay");

    if (!popup || !overlay) return;

    if (contactLink) {
        e.preventDefault();
        popup.style.display = "block";
        overlay.style.display = "block";
    }

    if (e.target.id === "contactClose" || e.target.id === "contactOverlay") {
        popup.style.display = "none";
        overlay.style.display = "none";
    }
});
</script>

<!-- botstrap js plugin -->
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.6/dist/js/bootstrap.bundle.min.js" integrity="sha384-j1CDi7MgGQ12Z7Qab0qlWQ/Qqz24Gc6BM0thvEMVjHnfYGF0rmFCozFSxQBxwHKO" crossorigin="anonymous"></script>

<!-- jq plugin -->
 

<!-- slick slider js plugin -->
 <script type="text/javascript" src="//cdn.jsdelivr.net/npm/slick-carousel@1.8.1/slick/slick.min.js"></script>

  <!-- Scripts -->
  <!-- jQuery -->
  <script src="<?php echo bloginfo('template_directory'); ?>/js/vendor/jquery.min.js"></script>

  <!-- Swiper JS -->
  <script src="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.js"></script>
  <!-- Bootstrap JS -->
  <script src="<?php echo bloginfo('template_directory'); ?>/js/vendor/bootstrap.bundle.min.js"></script>
  <!-- JS Script -->
  <!--<script src="<?php //echo bloginfo('template_directory'); ?>/js/swiper-script.js"></script>-->
  <!--<script src="<?php //echo bloginfo('template_directory'); ?>/js/submit-form.js"></script>-->
  <script src="<?php echo bloginfo('template_directory'); ?>/js/script.js"></script>
  <script src="<?php echo bloginfo('template_directory'); ?>/js/main.js"></script>
  <!-- Fancybox v5 JS -->
<script src="https://cdn.jsdelivr.net/npm/@fancyapps/ui@5/dist/fancybox/fancybox.umd.js"></script>
<!-- video slider popup js -->

<script>
  // Initialize Swiper (NO LOOP)
  const swiper = new Swiper(".myVideoSlider", {
    slidesPerView: 5,
    spaceBetween: 20,
    loop: true,  // <<--- Add this
    navigation: {
      nextEl: ".swiper-button-next",
      prevEl: ".swiper-button-prev",
    },
    autoplay: {
        delay: 2500,
        disableOnInteraction: false,
},
    breakpoints: {
      320: { slidesPerView: 1 },
      640: { slidesPerView: 3 },
      992: { slidesPerView: 5 }
    }
  });

  // Initialize Fancybox (Latest v5)
  Fancybox.bind("[data-fancybox='video-gallery']", {
    groupAll: true, // create a gallery group
    animated: true,
    dragToClose: true,
    Toolbar: {
      display: ["close"],
    }
  });
</script>
<!-- video listing popup js -->


<script>
    const slides = document.querySelectorAll(".slide");
const popup = document.getElementById("popupVideo");
const videoFrame = document.getElementById("videoFrame");
const closeBtn = document.querySelector(".close");

// Open Popup
slides.forEach(slide => {
  slide.addEventListener("click", () => {
    const videoSrc = slide.getAttribute("data-video");

    // If YouTube link
    if (videoSrc.includes("youtube") || videoSrc.includes("youtu.be")) {
      videoFrame.src = videoSrc + "?autoplay=1";
    } else {
      videoFrame.src = videoSrc;
    }

    popup.style.display = "flex";
  });
});

// Close Popup
closeBtn.addEventListener("click", () => {
  popup.style.display = "none";
  videoFrame.src = "";
});

// Close by clicking outside
popup.addEventListener("click", (e) => {
  if (e.target === popup) {
    popup.style.display = "none";
    videoFrame.src = "";
  }
});

</script>

<script>
jQuery(document).ready(function ($) {
    $('.health-topic-slider').owlCarousel({
        loop: true,
        margin: 18,
        nav: true,
        dots: true,
        autoplay: true,
        autoplayTimeout: 3500,
        autoplayHoverPause: true,
        smartSpeed: 700,
        navText: ['‹', '›'],
        responsive: {
            0: {
                items: 1
            },
            576: {
                items: 2
            },
            992: {
                items: 3
            }
        }
    });
});
</script>
<script>
document.addEventListener("DOMContentLoaded", function () {
    const ticker = document.querySelector(".hnt-ticker-sec");
    if (!ticker) return;

    const track = ticker.querySelector(".hnt-ticker-track");
    const prevBtn = ticker.querySelector(".hnt-prev");
    const nextBtn = ticker.querySelector(".hnt-next");

    if (!track || !prevBtn || !nextBtn) return;

    let originalCards = Array.from(track.querySelectorAll(".hnt-ticker-card"));
    let totalOriginal = originalCards.length;
    let index = 0;
    let timer = null;
    let isMoving = false;

    if (totalOriginal === 0) return;

    // Clone cards only once
    if (!track.classList.contains("hnt-cloned")) {
        originalCards.forEach(function (card) {
            track.appendChild(card.cloneNode(true));
        });

        originalCards.forEach(function (card) {
            track.appendChild(card.cloneNode(true));
        });

        track.classList.add("hnt-cloned");
    }

    const cards = track.querySelectorAll(".hnt-ticker-card");

    function getGap() {
        const style = window.getComputedStyle(track);
        return parseFloat(style.gap || style.columnGap) || 20;
    }

    function getCardWidth() {
        return cards[0].getBoundingClientRect().width + getGap();
    }

    function moveTo(animate) {
        track.style.transition = animate ? "transform 0.45s ease" : "none";
        track.style.transform = "translateX(-" + (index * getCardWidth()) + "px)";
    }

    function nextSlide() {
        if (isMoving) return;
        isMoving = true;

        index++;
        moveTo(true);

        setTimeout(function () {
            if (index >= totalOriginal) {
                index = 0;
                moveTo(false);
            }
            isMoving = false;
        }, 480);
    }

    function prevSlide() {
        if (isMoving) return;
        isMoving = true;

        if (index <= 0) {
            index = totalOriginal;
            moveTo(false);

            setTimeout(function () {
                index--;
                moveTo(true);
            }, 20);
        } else {
            index--;
            moveTo(true);
        }

        setTimeout(function () {
            isMoving = false;
        }, 500);
    }

    function startAuto() {
        stopAuto();
        timer = setInterval(nextSlide, 2500);
    }

    function stopAuto() {
        if (timer) {
            clearInterval(timer);
            timer = null;
        }
    }

    nextBtn.addEventListener("click", function () {
        nextSlide();
        startAuto();
    });

    prevBtn.addEventListener("click", function () {
        prevSlide();
        startAuto();
    });

    ticker.addEventListener("mouseenter", stopAuto);
    ticker.addEventListener("mouseleave", startAuto);

    window.addEventListener("resize", function () {
        moveTo(false);
    });

    moveTo(false);
    startAuto();
});
</script>
<script>
jQuery(document).ready(function($) {

    let timer;

    $('.search-field').on('keyup', function() {

        clearTimeout(timer);
        let keyword = $(this).val().trim();

        if (keyword.length < 1) {
            $('.auto-search-results').hide().empty();
            return;
        }

        timer = setTimeout(function() {
            $.ajax({
                url: '<?php echo admin_url("admin-ajax.php"); ?>',
                type: 'POST',
                data: {
                    action: 'auto_thread_search',
                    keyword: keyword
                },
                success: function(response) {
                    if (response.trim() !== '') {
                        $('.auto-search-results').html(response).show();
                    } else {
                        $('.auto-search-results').hide();
                    }
                }
            });
        }, 300);
    });

    // Optional: hide when clicking outside
    $(document).on('click', function(e) {
        if (!$(e.target).closest('.search-box').length) {
            $('.auto-search-results').hide();
        }
    });

});
</script>

  <!-- #scripts end -->
<?php wp_footer(); ?>

<!-- footer area end here -->