1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 | <?php if(isset($_POST['email'])) { $email=$_POST['email']; $act=$_REQUEST['act']; } else { $email=""; $act=""; } if($act=="send" && $email!="") { $name="Dolly Khan"; $contact="9999999999"; $company="Cody Paste"; $msg="Hi, i am new in web please suggest course."; $to = "info@vipulrai.com"; $subject = "Request From Vipul rai website"; $message = "\n\nName: ".$name. "\n\nEmail: ".$email. "\n\nContact: ".$contact. "\n\nCompany: ".$company. "\n\nMessage: ".$msg."\n\n"; $from = "$email"; $headers = "From:" . $from; $mail_sent = @mail( $to, $subject, $message, $headers ); if($mail_sent) { echo"<div class=alert alert-success>Thank You! We will get back to you as soon as possible!</div>"; } else { echo"<div class=alert alert-danger>Sorry! Please Try Again or send mail at vipulrai.com</div>"; } } ?> |