Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End Chris’s simple contact form doesn’t work

  • This topic is empty.
Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #42828
    AlirezaM
    Participant

    Hi all!

    I want to use the contact form which Chris is created and when I click on send button the message comes and tells “The message has been sent successfully” but actually I don’t get any emails.

    #125223
    AlirezaM
    Participant

    I’m on apache server now and using the script in live server.

    I also checked my spam folder but nothing is there.

    I thought it could because of I didn’t touch “$EmailFrom = “[email protected]”;”
    then I change it to mine but again it didn’t work.

    Please help!

    #125313
    dclardy
    Member

    Do you have PHP installed on the server? Or just Apache? It will not work with out PHP.

    #125329
    AlirezaM
    Participant

    I have these lines:

    $EmailFrom = “[email protected]”;

    $EmailTo = “[email protected]”;

    $Subject = “Nice & Simple Contact Form by CSS-Tricks”;

    $Name = Trim(stripslashes($_POST));

    $Subject = Trim(stripslashes($_POST));

    $Email = Trim(stripslashes($_POST));

    $Message = Trim(stripslashes($_POST));

    but yours is different from mine I think.

    #125334
    PicnicTutorials
    Participant

    Why don’t you just use a script that does work right out of the gate?

    #125457
    AlirezaM
    Participant

    @websitecodetutorials

    which script for example?

    @BenWalker

    I didn’t get exactly what to do. I want to use the mail script as chris’s and show a message for success or error after sending mails.

    #125461
    Alen
    Participant

    Post complete code here so we can see script in its entirety. From the code sample you provided it is unclear if you are passing variables to the mail() function correctly.

    #125467
    PicnicTutorials
    Participant
    #125511
    AlirezaM
    Participant

    @BenWalker

    I uploaded the file mail.php holding your codes on my hosting but it didn’t work then I decided to check in another hosting and it worked. So as you said it was about my hosting and I should talk with the moderators to see what they can do for me.

    Thank you so much for these kind helps! I really apperciate your work.

Viewing 9 posts - 1 through 9 (of 9 total)
  • The forum ‘Back End’ is closed to new topics and replies.