www.webdeveloper.com
Results 1 to 6 of 6

Thread: onSubmit write text

  1. #1
    Join Date
    Jul 2008
    Posts
    4

    onSubmit write text

    Hey, on my website im currently using a form where a user submits their E-mail and Name and they get put on my subscription list.
    When the user clicks submit, there really is no notification telling them that it worked successfully.

    What I'm trying to do is when the user clicks submit, text appears right above the form saying "You have successfully subscribed to {list name}."
    I do not want this to be a popup. Any idea on how to do this?

  2. #2
    Join Date
    Oct 2010
    Posts
    2
    Try using AJAX

  3. #3
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    21,654
    A "successfully" subscription can only be validated using server-side scripting.
    Just poping up a message is possible with JavaScript, but it can in no way be described as a "successfully" subscription.
    At least 98% of internet users' DNA is identical to that of chimpanzees

  4. #4
    Join Date
    Oct 2010
    Posts
    2
    Quote Originally Posted by Havens View Post
    Hey, on my website im currently using a form where a user submits their E-mail and Name and they get put on my subscription list.
    When the user clicks submit, there really is no notification telling them that it worked successfully.

    What I'm trying to do is when the user clicks submit, text appears right above the form saying "You have successfully subscribed to {list name}."
    I do not want this to be a popup. Any idea on how to do this?
    You can always put a label above to display the information you want.

  5. #5
    Join Date
    Sep 2008
    Location
    Akron, OH
    Posts
    1,112
    As vishnukumargr and Fang both referenced, you'll want to use server side scripting mixed with AJAX. I'd guess your server language is PHP, so I'd recommend doing some googling for "php ajax form" and read through some tutorials.

  6. #6
    Join Date
    Jul 2008
    Posts
    4
    Well the problem isn't so much checking whether or not it was successful, im using the subscription company 'aweber' to do all that. all i need is some text saying "Thank you for subscribing to the newsletter." to appear after they click submit. because right now they click submit and it just redirects them back to the page.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles