From 35898947431e1f4f06c35981c9fa3876ef207250 Mon Sep 17 00:00:00 2001 From: bender Date: Sun, 10 May 2026 13:37:09 +0000 Subject: [PATCH] Update src/app/page.tsx --- src/app/page.tsx | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/src/app/page.tsx b/src/app/page.tsx index daeabfb..f2759b3 100644 --- a/src/app/page.tsx +++ b/src/app/page.tsx @@ -18,6 +18,23 @@ export default function LandingPage() { window.location.href = "tel:5867959955"; }; + const handleRequestService = async (email: string) => { + try { + const response = await fetch('/api/request-service', { + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + body: JSON.stringify({ email, type: 'Request Service' }), + }); + if (response.ok) { + alert('Service request sent successfully!'); + } else { + alert('Failed to send request.'); + } + } catch (error) { + console.error('Error:', error); + } + }; + return ( @@ -252,4 +270,4 @@ export default function LandingPage() { ); -} \ No newline at end of file +}