mirror of
https://github.com/myronblair/tomtomgames-app
synced 2026-06-30 17:49:57 -05:00
17 lines
522 B
PHP
17 lines
522 B
PHP
<?php
|
|
require_once __DIR__ . '/../../includes/auth.php';
|
|
header('Content-Type: application/json');
|
|
|
|
if ($_SERVER['REQUEST_METHOD'] !== 'POST') {
|
|
echo json_encode(['success'=>false,'error'=>'Method not allowed']); exit;
|
|
}
|
|
|
|
$data = json_decode(file_get_contents('php://input'), true);
|
|
$email = trim($data['email'] ?? '');
|
|
|
|
if (empty($email) || !filter_var($email, FILTER_VALIDATE_EMAIL)) {
|
|
echo json_encode(['success'=>false,'error'=>'Valid email required']); exit;
|
|
}
|
|
|
|
echo json_encode(resendVerification($email));
|