Skip to content

Jander events #47

Description

@lnewe29

Janda Events is a Gold Coast-based boutique entertainment and celebrant collective, specialising in high-energy wedding soundtracks, live musicians, and modern celebrants. Founded by Jake and Lei-Ahna Newell, it is a family-run business focused on bringing personal, "good vibes" to weddings across South-East Queensland and Northern New South Wales all about bringing the fun and if you go search up gender events you’ll find some of their pictures and see how such a good time it is they do MC Dj celebrant musician they do all of the things they’re the best on the Gold Coast they’ve even gone to New Zealand to do a wedding

body {
font-family: Arial, sans-serif;
padding: 30px;
background: #f5f5f5;
}

form {
background: white;
padding: 20px;
border-radius: 10px;
max-width: 500px;
}

input,
textarea,
button {
width: 100%;
padding: 12px;
margin-top: 10px;
box-sizing: border-box;
}

button {
cursor: pointer;
}

.hidden {
display: none;
}

#successMessage {
margin-top: 20px;
color: green;
font-weight: bold;
}
h1>Booking Enquiry

<input
    type="text"
    id="name"
    placeholder="Your Name"
    required
>

<input
    type="email"
    id="email"
    placeholder="Your Email"
    required
>

<textarea
    id="message"
    placeholder="Your Message"
    rows="5"
    required
></textarea>

<button type="submit">
    Submit
</button>
Your enquiry has been sent successfully!
<script src="https://cdn.jsdelivr.net/npm/@emailjs/browser@4/dist/email.min.js"></script> <script src="script.js"></script>

===============================
// EmailJS Setup
// ===============================
emailjs.init("YOUR_PUBLIC_KEY");

// ===============================
// Form Elements
// ===============================
const bookingForm = document.getElementById('bookingForm');
const successMessage = document.getElementById('successMessage');

// ===============================
// Form Submit
// ===============================
bookingForm.addEventListener('submit', function(e) {
e.preventDefault();

const name = document.getElementById('name').value.trim();
const email = document.getElementById('email').value.trim();
const message = document.getElementById('message').value.trim();

// Name validation
if (name.length < 2) {
    alert('Please enter a valid name.');
    return;
}

// Email validation
const emailPattern = /^[^ ]+@[^ ]+\.[a-z]{2,3}$/;

if (!email.match(emailPattern)) {
    alert('Please enter a valid email address.');
    return;
}

// Message validation
if (message.length < 10) {
    alert('Message must be at least 10 characters.');
    return;
}

// Submit button loading state
const submitButton = bookingForm.querySelector('button');
submitButton.disabled = true;
submitButton.innerText = 'Sending...';

// Send email
emailjs.send("YOUR_SERVICE_ID", "YOUR_TEMPLATE_ID", {
    to_email: "lei.newell@outlook.com",
    name: name,
    email: email,
    message: message
})

.then(function() {

    successMessage.classList.remove('hidden');
    bookingForm.reset();

    submitButton.disabled = false;
    submitButton.innerText = 'Submit';

})

.catch(function(error) {

    console.error('Email failed:', error);

    alert('Something went wrong. Please try again.');

    submitButton.disabled = false;
    submitButton.innerText = 'Submit';
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions