I have following php file which I am placing as a form action,the coding seems right as i get all variables value when I echo the statements,but I dont know what happen to this,I am not getting this to email-id. Also my form tag is like
What server are you using, are you trying to send email from localhost.
Just a note remove your email address from the above code. You might get lotsa spam emails.
The mail() function only works if the server knows what e-mail to send from and what SMTP server to use for sending. As ~realin suggested, if you are trying to do this from localhost, you likely haven't set up these variables. Otherwise, it's a matter of whether your host has set them up for you. I'd suggest using a more capable mailing library for PHP like SwiftMailer.