Jump to content

help with my form


ssj4sunny

Recommended Posts

hi there guys, im pretty new to php and i need it to process my form.

<?php
  $name = $_REQUEST ['name'] ;
  $email = $_REQUEST ['email'] ;
  $what = $_REQUEST ['what'] ;

  mail( "[email protected]", "free quote",
    $email, $what, "From: $name" );
  header( "Location: http://sunny-shah.co.uk");
?>

 

i tried out the form here:

  http://sunny-shah.co.uk/services.html

 

but i never got an email in my inbox when the form was sent

 

help would be appreciated

thank you,

sunny

Link to comment
https://forums.phpfreaks.com/topic/174835-help-with-my-form/
Share on other sites

email() function params:

mail($to, $subject, $message, $headers);

 

<?php

$name = $_REQUEST ['name'] ;
  $email = $_REQUEST ['email'] ;
  $what = $_REQUEST ['what'] ;
  $headers .= 'From: '.$name.' <'.$email.'>' . "\r\n";

  mail( "[email protected]", "free quote", $what, $headers );
  header( "Location: http://sunny-shah.co.uk");
?>

Link to comment
https://forums.phpfreaks.com/topic/174835-help-with-my-form/#findComment-921418
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.