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

Nice and Simple sends no content

  • # September 12, 2008 at 2:11 am

    Using the Nice & Simple older version, I receive the email, with subject, to, from, but none of the content shown here:

    Code:
    $Name = Trim(stripslashes($_POST[‘Name’]));
    $Tel = Trim(stripslashes($_POST[‘Tel’]));
    $Email = Trim(stripslashes($_POST[‘Email’]));
    $Message = Trim(stripslashes($_POST[‘Message’]));
    box
    # September 12, 2008 at 5:02 am

    Check that the information that is being sent from the form is correct – check for simple spelling mistakes are syntax errors. Post your entire code, html form + php process script if you need help.

    # September 12, 2008 at 9:27 am

    Thank you.

    Here’s the php:

    Code:
    < ?php $EmailFrom = "form@andrewsontheweb.com"; $EmailTo = "jack@andrewsontheweb.com"; $Subject = "Inquiry from AndrewsOnTheWeb.com"; $Name = Trim(stripslashes($_POST['Name'])); $Tel = Trim(stripslashes($_POST['Tel'])); $Email = Trim(stripslashes($_POST['Email'])); $Message = Trim(stripslashes($_POST['Message'])); // validation $validationOK=true; if (!$validationOK) { print "“;
    exit;
    }

    // prepare email body text
    $Body = “”;
    $Body .= “Name: “;
    $Body .= $Name;
    $Body .= “n”;
    $Body .= “Tel: “;
    $Body .= $Tel;
    $Body .= “n”;
    $Body .= “Email: “;
    $Body .= $Email;
    $Body .= “n”;
    $Body .= “Message: “;
    $Body .= $Message;
    $Body .= “n”;

    // send email
    $success = mail($EmailTo, $Subject, $Body, “From: < $EmailFrom>“);

    // redirect to success page
    if ($success){
    print ““;
    }
    else{
    print ““;
    }
    ?>

    and the html:

    Code:
    < !DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">





    Dallas advertising agency, web designWeb design Dallas, advertising agency Dallas
    Dallas web design and advertising agencyWeb design and advertising agency in Dallas TX
    Dallas web design and advertising agency in DallasWeb site design, Advertising agency
    Andrews experienc

    Got a question, suggestion, comment or ? Let us know. We’ll respond asap.











    Web design spacer
    Home | Experience
    | Portfolio | Contact Us

    Andrews & Associates – 9418 Amberton Parkway – Dallas, TX USA 75243 – Ph: 469-330-9122


    and last, the URL of the page:
    http://andrewsontheweb.com/forms/contact_andrews.html

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

You must be logged in to reply to this topic.