PHP Form Question

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Scuzzelbutt
    New Member
    • Dec 2007
    • 1

    PHP Form Question

    I have just recently started creating PHP Forms but I am still learning. One of the snags I ran into has been bothersome for the last week or so. I have created a PHP form but it's very long and if the client doesnt fill in lets say 1/2 of the form. When the email form is printed out it takes a lot of paper. I would like to create something where only the fields that have something in them is submitted. Can anyone help me out with this?

    My form works just as a normal php/html form works then sends to a 2 include files which sends an email to the client and one to defualt info@domain.com .
  • nothing1
    New Member
    • Nov 2007
    • 30

    #2
    what about for every POST variable you put
    [PHP]
    $var = $_POST['answer1'];

    if($var != ''){print "Your response was $var";}[/PHP]

    I suggest you read up on if else statements

    Comment

    Working...