Treehouse: Grow your CSS skills. Land your dream job.

Thankyou without leaving page (Contact form)

  • # May 25, 2010 at 8:04 am

    Hello all.

    I have downloaded and set up the simple contact form that chris has kindly donated. All is working as it should.
    I would like to be able to have the "Your message has been sent" appear next to the contact form or above (some sort of pop up). I dont want to go to a separate Thankyou page.

    Does anyone have any ideas how to do this?

    Thanks all

    # May 25, 2010 at 9:41 am

    You will have to submit the form via Ajax.

    Basically you have a PHP file that you send the data to via Ajax and it processes it and spits out a response – you can then show that response on the same page without reloading.

    There are lots of tuts on that I am sure you can find one if you Google that kinda thing :D

    # May 25, 2010 at 10:18 am

    Cheers for the hint. Ill look around.


    # May 25, 2010 at 10:45 am

    This might be useful :) … ssion.html

    # May 25, 2010 at 11:10 am

    Thankyou, Ive read it and Its all greek to me Rob. I have no idea how to implement this into the form I have.
    So much code to say thanks, Ill be in touch! :roll:

    cheers again

    # May 25, 2010 at 11:43 am

    It is all Greek uh. It was one of the harder things I’ve done. You could try mine. … submit.php

    # May 25, 2010 at 12:12 pm

    I think I MAY be able to follow this one Eric. Many thanks. Ill let you know.

    # May 27, 2010 at 2:38 am
    "Eric" wrote:
    It is all Greek uh. It was one of the harder things I’ve done. You could try mine. … submit.php

    Hi Eric.

    I stand corrected. I wasnt able to follow. At least in part. I got your example working fine but when I try to implement this into my existing form it all goes wrong. I can get the error message to more or less appear but nothing else.

    Is there any chance you could take a quick scan and tell me what might be the cause.

    Many thanks eric.

    # May 27, 2010 at 10:41 am

    Do you have a local working copy of my demo? If not do this first. And then reverse engener it into yours. I’m sorry I can’t be of any further help. But if I was take a crack at figureing out your missed step that is what I would have to do.

Viewing 9 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic.