CONTACT INFO:
Book Appointment Now
`;
// Wire the form for AJAX submit to /stk/stkpush.php
const form = mount.querySelector('form[data-stk]');
if (!form) return;
const feedback = mount.querySelector('[data-feedback]');
const phoneInput = form.querySelector('input[name="phone"]');
// Add hidden fields for post_id and unlock_session
let hiddenPost = form.querySelector('input[name="post_id"]');
if (!hiddenPost) {
hiddenPost = document.createElement('input');
hiddenPost.type = 'hidden';
hiddenPost.name = 'post_id';
form.appendChild(hiddenPost);
}
hiddenPost.value = String(postId);
let hiddenSess = form.querySelector('input[name="unlock_session"]');
if (!hiddenSess) {
hiddenSess = document.createElement('input');
hiddenSess.type = 'hidden';
hiddenSess.name = 'unlock_session';
form.appendChild(hiddenSess);
}
hiddenSess.value = sessionKey;
form.addEventListener('submit', function(e) {
e.preventDefault();
feedback.textContent = '';
const raw = (phoneInput.value || '').trim();
if (!/^[0-9]{9}$/.test(raw) || raw[0] !== '7') {
feedback.textContent = 'Enter phone as 7XXXXXXXX';
feedback.style.color = 'red';
return;
}
feedback.textContent = 'Sending STK Push...';
feedback.style.color = '#444';
fetch('/stk/stkpush.php', {
method: 'POST',
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
body: new URLSearchParams(new FormData(form)).toString()
}).then(r => r.json()).then(j => {
if (j && j.success) {
feedback.textContent = 'Prompt sent. Check your phone and enter M-PESA PIN...';
feedback.style.color = 'green';
// Start polling for unlock
startPollingUnlock(postId, () => {
feedback.textContent = 'Payment received. Unlocking contact...';
feedback.style.color = 'green';
showContactsAfterUnlock();
});
} else {
feedback.textContent = (j && j.error) ? j.error : 'Failed to start STK Push';
feedback.style.color = 'red';
}
}).catch(() => {
feedback.textContent = 'Network error. Try again.';
feedback.style.color = 'red';
});
});
// Manual receipt popup
const openReceipt = area.querySelector('#openReceipt');
if (openReceipt) {
openReceipt.addEventListener('click', openReceiptPopup);
}
}
function openReceiptPopup() {
const overlay = document.getElementById('receiptOverlay');
const popup = document.getElementById('receiptPopup');
const err = document.getElementById('receiptError');
err.style.display = 'none';
err.textContent = '';
overlay.style.display = 'block';
popup.style.display = 'block';
}
function closeReceiptPopup() {
document.getElementById('receiptOverlay').style.display = 'none';
document.getElementById('receiptPopup').style.display = 'none';
}
document.getElementById('closeReceiptBtn').addEventListener('click', closeReceiptPopup);
document.getElementById('receiptOverlay').addEventListener('click', closeReceiptPopup);
document.getElementById('submitReceiptBtn').addEventListener('click', function() {
const receipt = (document.getElementById('receiptInput').value || '').trim();
const err = document.getElementById('receiptError');
if (!receipt) {
err.textContent = 'Please enter a receipt code.';
err.style.display = 'block';
return;
}
const postId = 582;
const sessionKey = ensureUnlockSession();
const body = new URLSearchParams();
body.set('post_id', String(postId));
body.set('unlock_session', sessionKey);
body.set('receipt', receipt);
fetch('/stk/manual_unlock.php', {
method: 'POST',
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
body: body.toString()
}).then(r => r.json()).then(j => {
if (j && j.unlocked) {
closeReceiptPopup();
showContactsAfterUnlock();
} else {
err.textContent = (j && j.error) ? j.error : 'Unable to unlock. Check receipt code.';
err.style.display = 'block';
}
}).catch(() => {
err.textContent = 'Network error. Try again.';
err.style.display = 'block';
});
});
const area = document.getElementById('appointmentArea');
const bookBtn = document.getElementById('bookBtn');
let areaVisible = false;
function showContactsAfterUnlock() {
renderContacts(area, '+254116329236', '254116329236');
areaVisible = true;
}
bookBtn.addEventListener('click', async function() {
if (areaVisible) {
// toggle off
area.innerHTML = '';
areaVisible = false;
return;
}
// If premium active, show immediately
const isPremiumActive = false;
if (isPremiumActive) {
showContactsAfterUnlock();
return;
}
// Otherwise check if already unlocked this session
const unlocked = await isUnlocked(582);
if (unlocked) {
showContactsAfterUnlock();
} else {
renderPayment(area, 582);
areaVisible = true;
}
});
Show Instructions to make payment
Instructions to make payment:
* Click 'Book Appointment Now' button.
* Enter m-pesa number that makes payment then click 'submit payment' button.
* You will receive a prompt on your phone.
* Confirm payment using M-PESA Pin.
* Click the 'See Contact' button below.
* Enter m-pesa transaction Id.
* Click the 'Submit code' button to get Shann's contact details.
Note: Amount paid is not a hookup fee. No refunds.
Name: Shann
Gender: Female
Age: 24
Skin Color: Brown
Body Size: Medium
Sexuality: Bisexual
Availability: Incall & Outcall