Skip to content

Added success message to the newsletter form#3

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

Added success message to the newsletter form#3
akshay0611 wants to merge 1 commit intocodewithsadee:masterfrom
akshay0611:add-newsletter-success-message

Conversation

@akshay0611
Copy link

This PR enhances the newsletter subscription form by adding a success message that appears upon submission and disappears after 4 seconds. The input field resets after submission, improving user experience.

Changes:

  • Added a success message that confirms subscription.
  • Implemented JavaScript to hide the message after 4 seconds.
  • Ensured the input field resets upon submission.

Fixes: #2

Copy link

@Imran-imtiaz48 Imran-imtiaz48 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your JavaScript implementation for filtering and newsletter subscription is well-structured and efficient. The filterBox.setAttribute method dynamically updates the filter attribute, ensuring smooth interactivity. The event listener for the newsletter form prevents default submission, displays a success message, resets the form, and automatically hides the message after four seconds, enhancing user experience. Your code follows best practices, keeping it clean and easy to maintain. For improvement, consider adding animations to the success message for a smoother UX. Overall, this is a solid and functional implementation worth showcasing on GitHub...

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

2 participants