title: Can't get my php form working (cant send the email)
body: <p>To being with, Im really bad with PHP, not my area. Sorry for any stupid stuff I might say</p>
  
  <p>EDIT: I tried echoing the vars as you guys sayd to, and comes out I cant get any value out of it.</p>
  
  <p>EDIT2: Those "class required" works for my jquery validation script. You guys think i should post it too?</p>
  
  <p>Well, im facing a php contact form problem. I dont know much about php too, so this make stuff harder.</p>
  
  <p>Well, I've tried mailtest.php to check if it was my hosting, but it is working ok. So here is the code:</p>
  
  <pre><code>&lt;form class="validate" method="post" action="send_form_email.php"&gt;
  
      &lt;span class="fill"&gt;Todos os campos são obrigatórios.&lt;/span&gt;
      &lt;span&gt;&lt;label&gt;Nome:&lt;/label&gt;&lt;input name="nome" type="text" class="required" /&gt;&lt;/span&gt;&lt;br /&gt;
      &lt;span&gt;&lt;label&gt;E-mail:&lt;/label&gt;&lt;input name="mail" type="text" class="required email" /&gt;&lt;/span&gt;&lt;br /&gt;
      &lt;span&gt;&lt;label&gt;Empresa:&lt;/label&gt;&lt;input name="empresa" type="text" class="required" /&gt;&lt;/span&gt;&lt;br /&gt;
      &lt;span&gt;&lt;label&gt;Telefone:&lt;/label&gt;&lt;input style="width: 150px;" name="phone" type="text" class="required" /&gt;&lt;/span&gt;&lt;br /&gt;                   
      &lt;span&gt;&lt;label&gt;Mensagem:&lt;/label&gt;&lt;textarea name="mensagem" cols="38" rows="8" class="required"&gt;&lt;/textarea&gt;&lt;/span&gt;&lt;br /&gt;
      &lt;span&gt;&lt;input class="btn" type="submit" name="submit" value="Enviar" /&gt;&lt;/span&gt;
  
  &lt;/form&gt;
  </code></pre>
  
  <p>And here it is my php coding:</p>
  
  <pre><code>&lt;?php
  if(isset($_POST['submit'])) {
  
  $to = "fernando_fleury@hotmail.com";
  $subject = "Contato Website - Nicotec";
  $name = $_POST['nome'];
  $email = $_POST['mail'];
  $empresa = $_POST['empresa'];
  $phone = $_POST['phone'];
  $message = $_POST['mensagem'];
  
  $body = "De: $name_field\n E-Mail: $email\n Empresa: $empresa\n Telefone: $phone\n Mensagem:\n $message";
  
  mail($to, $subject, $body);
  }
  
  header('Location: contato.html');
  
  ?&gt;
  </code></pre>
  
  <p>It is possible to check it live too on: <a href="http://www.fernandofleury.com.br/preview/nicotec/contato.html" rel="nofollow">http://www.fernandofleury.com.br/preview/nicotec/contato.html</a></p>
  
  <p>What am i doing wrong here? Thanks in advance.</p>