Skip to content

🎉 Added Success Message to Newsletter Form#6

Open
akshay0611 wants to merge 1 commit intocodewithsadee:masterfrom
akshay0611:add-newsletter-success-message
Open

🎉 Added Success Message to Newsletter Form#6
akshay0611 wants to merge 1 commit intocodewithsadee:masterfrom
akshay0611:add-newsletter-success-message

Conversation

@akshay0611
Copy link
Copy Markdown

📢 Description

This PR enhances the newsletter subscription form by adding a success message that appears after a valid submission. The message disappears after 3 seconds, ensuring a smooth user experience.

✨ Changes Implemented

  • ✅ Added a <p> element to display the success message.
  • 🎨 Styled the success message using CSS for better visibility.
  • ⚡ Implemented JavaScript logic to:
    • Show the message upon form submission.
    • Validate the email input.
    • Reset the form after submission.
    • Auto-hide the message after 3 seconds.

🚀 How to Test

  1. Enter a valid email in the input field.
  2. Click "Join".
  3. Observe the success message appearing.
  4. Wait 3 seconds to see it disappear.

🏷 Related Issue

Closes #5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Success Message to Newsletter Form

1 participant