158 lines
9.1 KiB
PHP
158 lines
9.1 KiB
PHP
</main>
|
|
<footer class="bg-white border-top py-5">
|
|
<div class="container">
|
|
<div class="row g-4">
|
|
<div class="col-lg-4">
|
|
<a class="navbar-brand fw-bold text-success d-flex align-items-center" href="/">
|
|
<?php if (get_setting('site_icon')): ?>
|
|
<img src="/<?php echo get_setting('site_icon'); ?>" alt="Logo" class="me-2" style="height: 30px;">
|
|
<?php else: ?>
|
|
<i class="bi bi-robot"></i>
|
|
<?php endif; ?>
|
|
<?php echo htmlspecialchars(get_setting('site_name', 'ApkNusa')); ?>
|
|
</a>
|
|
<p class="text-muted mt-3 pe-lg-5">
|
|
<?php echo htmlspecialchars(get_setting('site_name', 'ApkNusa')); ?> <?php echo __('footer_about'); ?>
|
|
</p>
|
|
</div>
|
|
<div class="col-6 col-lg-2">
|
|
<h6 class="fw-bold mb-3"><?php echo __('popular'); ?></h6>
|
|
<ul class="list-unstyled">
|
|
<li><a href="/" class="text-muted text-decoration-none py-1 d-block small"><?php echo __('top_games'); ?></a></li>
|
|
<li><a href="/" class="text-muted text-decoration-none py-1 d-block small"><?php echo __('top_apps'); ?></a></li>
|
|
<li><a href="/" class="text-muted text-decoration-none py-1 d-block small"><?php echo __('new_releases'); ?></a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="col-6 col-lg-2">
|
|
<h6 class="fw-bold mb-3"><?php echo __('resources'); ?></h6>
|
|
<ul class="list-unstyled">
|
|
<li><a href="/blog" class="text-muted text-decoration-none py-1 d-block small">Blog</a></li>
|
|
<li><a href="/help-center" class="text-muted text-decoration-none py-1 d-block small"><?php echo __('support_center'); ?></a></li>
|
|
<li><a href="/terms-of-service" class="text-muted text-decoration-none py-1 d-block small"><?php echo __('terms_of_service'); ?></a></li>
|
|
<li><a href="/privacy-policy" class="text-muted text-decoration-none py-1 d-block small"><?php echo __('privacy_policy'); ?></a></li>
|
|
<li><a href="/contact" class="text-muted text-decoration-none py-1 d-block small">Contact Us</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="col-lg-4">
|
|
<h6 class="fw-bold mb-3"><?php echo __('subscribe'); ?></h6>
|
|
<p class="text-muted small"><?php echo __('subscribe_text'); ?></p>
|
|
<div class="input-group">
|
|
<input type="email" id="newsletter-email" class="form-control border-light-subtle" placeholder="<?php echo __('email_placeholder'); ?>">
|
|
<button class="btn btn-success px-3" id="newsletter-btn" type="button"><?php echo __('subscribe'); ?></button>
|
|
</div>
|
|
<div id="newsletter-msg" class="mt-2 small"></div>
|
|
</div>
|
|
</div>
|
|
<hr class="my-5 text-black-50 opacity-25">
|
|
<div class="row align-items-center">
|
|
<div class="col-md-6 text-center text-md-start">
|
|
<span class="text-muted small">© <?php echo date('Y'); ?> <?php echo htmlspecialchars(get_setting('site_name', 'ApkNusa')); ?>. <?php echo __('all_rights_reserved'); ?></span>
|
|
</div>
|
|
<div class="col-md-6 text-center text-md-end mt-3 mt-md-0">
|
|
<div class="d-flex justify-content-center justify-content-md-end gap-3">
|
|
<?php if ($fb = get_setting('facebook_url')): ?>
|
|
<a href="<?php echo $fb; ?>" target="_blank" class="text-muted"><i class="bi bi-facebook"></i></a>
|
|
<?php endif; ?>
|
|
<?php if ($tw = get_setting('twitter_url')): ?>
|
|
<a href="<?php echo $tw; ?>" target="_blank" class="text-muted"><i class="bi bi-twitter-x"></i></a>
|
|
<?php endif; ?>
|
|
<?php if ($ig = get_setting('instagram_url')): ?>
|
|
<a href="<?php echo $ig; ?>" target="_blank" class="text-muted"><i class="bi bi-instagram"></i></a>
|
|
<?php endif; ?>
|
|
<?php if ($gh = get_setting('github_url')): ?>
|
|
<a href="<?php echo $gh; ?>" target="_blank" class="text-muted"><i class="bi bi-github"></i></a>
|
|
<?php endif; ?>
|
|
<?php if ($tg = get_setting('telegram_url')): ?>
|
|
<a href="<?php echo $tg; ?>" target="_blank" class="text-muted"><i class="bi bi-telegram"></i></a>
|
|
<?php endif; ?>
|
|
<?php if ($wa = get_setting('whatsapp_url')): ?>
|
|
<a href="<?php echo $wa; ?>" target="_blank" class="text-muted"><i class="bi bi-whatsapp"></i></a>
|
|
<?php endif; ?>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</footer>
|
|
|
|
<!-- AI Chat Assistant -->
|
|
<div id="ai-chat-wrapper" class="fixed-bottom p-3 d-flex flex-column align-items-end" style="z-index: 1050; pointer-events: none;">
|
|
<div id="ai-chat-window" class="card shadow-lg border-0 mb-3 d-none" style="width: 350px; max-width: 90vw; height: 450px; pointer-events: auto; border-radius: 20px;">
|
|
<div class="card-header bg-success text-white py-3 d-flex justify-content-between align-items-center" style="border-radius: 20px 20px 0 0;">
|
|
<div class="d-flex align-items-center">
|
|
<div class="bg-white rounded-circle p-1 me-2">
|
|
<i class="bi bi-robot text-success"></i>
|
|
</div>
|
|
<span class="fw-bold">ApkNusa AI</span>
|
|
</div>
|
|
<button type="button" class="btn-close btn-close-white" id="close-ai-chat"></button>
|
|
</div>
|
|
<div class="card-body overflow-auto p-3" id="ai-chat-messages" style="background: var(--subtle-bg);">
|
|
<div class="mb-3">
|
|
<div class="bg-white p-3 rounded-4 shadow-sm small" style="max-width: 85%; border-bottom-left-radius: 0 !important;">
|
|
Hello! How can I help you today?
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="card-footer bg-white border-0 p-3" style="border-radius: 0 0 20px 20px;">
|
|
<div class="input-group">
|
|
<input type="text" id="ai-chat-input" class="form-control border-light-subtle rounded-pill-start px-3" placeholder="Type a message...">
|
|
<button class="btn btn-success rounded-pill-end px-3" id="send-ai-chat">
|
|
<i class="bi bi-send-fill"></i>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<button class="btn btn-success shadow-lg d-flex align-items-center justify-content-center p-0 rounded-circle" id="toggle-ai-chat" style="width: 60px; height: 60px; pointer-events: auto;">
|
|
<i class="bi bi-chat-dots-fill fs-3"></i>
|
|
</button>
|
|
</div>
|
|
|
|
<style>
|
|
#ai-chat-messages::-webkit-scrollbar {
|
|
width: 4px;
|
|
}
|
|
#ai-chat-messages::-webkit-scrollbar-thumb {
|
|
background: #10B981;
|
|
border-radius: 10px;
|
|
}
|
|
</style>
|
|
|
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
|
|
<script src="/assets/js/main.js?v=<?php echo time(); ?>"></script>
|
|
<script>
|
|
document.getElementById('newsletter-btn').addEventListener('click', function() {
|
|
const email = document.getElementById('newsletter-email').value;
|
|
const msg = document.getElementById('newsletter-msg');
|
|
|
|
if (!email) return;
|
|
|
|
this.disabled = true;
|
|
this.innerHTML = '<span class="spinner-border spinner-border-sm"></span>';
|
|
|
|
fetch('/api/newsletter/subscribe', {
|
|
method: 'POST',
|
|
headers: { 'Content-Type': 'application/json' },
|
|
body: JSON.stringify({ email: email })
|
|
})
|
|
.then(res => res.json())
|
|
.then(data => {
|
|
this.disabled = false;
|
|
this.innerHTML = '<?php echo __("subscribe"); ?>';
|
|
if (data.success) {
|
|
msg.innerHTML = '<span class="text-success">' + data.success + '</span>';
|
|
document.getElementById('newsletter-email').value = '';
|
|
} else {
|
|
msg.innerHTML = '<span class="text-danger">' + data.error + '</span>';
|
|
}
|
|
})
|
|
.catch(err => {
|
|
this.disabled = false;
|
|
this.innerHTML = '<?php echo __("subscribe"); ?>';
|
|
msg.innerHTML = '<span class="text-danger">An error occurred.</span>';
|
|
});
|
|
});
|
|
</script>
|
|
<?php echo get_setting('body_js'); ?>
|
|
</body>
|
|
</html>
|