<?php 


/*    ***********************  start   ***********************      */
     
	if(isset($_POST['popup_form'])){
		$pop_name = isset($_POST['pop_name'])?$_POST['pop_name']:"";
		$pop_email = isset($_POST['pop_email'])?$_POST['pop_email']:"";
		$pop_phone = isset($_POST['pop_phone'])?$_POST['pop_phone']:"";
        $pop_msg = isset($_POST['pop_msg'])?$_POST['pop_msg']:"";
		$to  = 'helpdesk@alphacorp.business';
		
	
		
		$headers  = 'MIME-Version: 1.0' . "\r\n";
		$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
		$subject = "Sign-Up for 50% Discounts";
		$message = "PopUP Form.
					<table border='2'>
				    	<tr><td>First Name:</td><td>".$pop_name."</td></tr>
						<tr><td>Email:</td><td>".$pop_email."</td></tr>
						<tr><td>Phone No:</td><td>".$pop_phone."</td></tr>
						<tr><td>Message</td><td>".$pop_msg."</td></tr>
					</table>";
		$message = nl2br($message);
		if(mail($to, $subject, $message, $headers)){
			header('location:https://alphacorp.business/thankyou.html');
		}
	}

        	/*    ***********************  end   ***********************      */

/*    ***********************  start   ***********************      */
		if(isset($_POST['banner_btn'])){
		$b_name = isset($_POST['b_name'])?$_POST['b_name']:"";
		$b_email = isset($_POST['b_email'])?$_POST['b_email']:"";
		$b_num = isset($_POST['b_num'])?$_POST['b_num']:"";
		$b_msg = isset($_POST['b_num'])?$_POST['b_msg']:"";


		$to  = 'helpdesk@alphacorp.business';
		
	
		$headers  = 'MIME-Version: 1.0' . "\r\n";
		$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
		$subject = "Sign-Up for 50% Discounts";
		$message = "Banner Form.
					<table border='2'>
				    	<tr><td>First Name:</td><td>".$b_name."</td></tr>
						<tr><td>Email:</td><td>".$b_email."</td></tr>
						<tr><td>Phone No:</td><td>".$b_num."</td></tr>
						<tr><td>Message</td><td>".$b_msg."</td></tr>
					</table>";
		$message = nl2br($message);
		if(mail($to, $subject, $message, $headers)){
			header('location:https://alphacorp.business/thankyou.html');
		}
	}
   	/*    ***********************  end   ***********************      */

/*    ***********************  start   ***********************      */
     
	if(isset($_POST['s13_btn'])){
		$s13_name = isset($_POST['s13_name'])?$_POST['s13_name']:"";
		$s13_email = isset($_POST['s13_email'])?$_POST['s13_email']:"";
		$s13_num = isset($_POST['s13_num'])?$_POST['s13_num']:"";
		$s13_lnum = isset($_POST['s13_lnum'])?$_POST['s13_lnum']:"";

		$to  = 'helpdesk@alphacorp.business';
		
	
		
		$headers  = 'MIME-Version: 1.0' . "\r\n";
		$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
		$subject = "Sign-Up for 50% Discounts";
		$message = "PopUP Form.
					<table border='2'>
				    	<tr><td>First Name:</td><td>".$s13_name."</td></tr>
				    	<tr><td>Last Name</td><td>".$s13_lnum."</td></tr>
						<tr><td>Email:</td><td>".$s13_email."</td></tr>
						<tr><td>Phone No:</td><td>".$s13_num."</td></tr>
						
					</table>";
		$message = nl2br($message);
		if(mail($to, $subject, $message, $headers)){
			header('location:https://alphacorp.business/thankyou.html');
		}
	}

        	/*    ***********************  end   ***********************      */
        	

/*    ***********************  start   ***********************      */
     
	if(isset($_POST['foot_btn'])){
		$f_name = isset($_POST['f_name'])?$_POST['f_name']:"";
		$l_name = isset($_POST['l_name'])?$_POST['l_name']:"";
		$foot_email = isset($_POST['foot_email'])?$_POST['foot_email']:"";
		$foot_num = isset($_POST['foot_num'])?$_POST['foot_num']:"";
		$foot_msg = isset($_POST['foot_msg'])?$_POST['foot_msg']:"";

		$to  = 'helpdesk@alphacorp.business';
		
	
		
		$headers  = 'MIME-Version: 1.0' . "\r\n";
		$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
		$subject = "Sign-Up for 50% Discounts";
		$message = "PopUP Form.
					<table border='2'>
				    	<tr><td>First Name:</td><td>".$f_name."</td></tr>
				    	<tr><td>Last Name</td><td>".$l_name."</td></tr>
						<tr><td>Email:</td><td>".$foot_email."</td></tr>
						<tr><td>Phone No:</td><td>".$foot_num."</td></tr>
						<tr><td>Message:</td><td>".$foot_msg."</td></tr>
						
					</table>";
		$message = nl2br($message);
		if(mail($to, $subject, $message, $headers)){
			header('location:https://alphacorp.business/thankyou.html');
		}
	}

        	/*    ***********************  end   ***********************      */

        	
   	/*    ***********************  Section Form   ***********************      */
	
   	/*    ***********************  end   ***********************      */


/*    ***********************  start***********************      */
if(isset($_POST['contact_sbmit_btn'])){
		$contact_name = isset($_POST['contact_name'])?$_POST['contact_name']:"";
		$contact_email = isset($_POST['contact_email'])?$_POST['contact_email']:"";
		$contact_number = isset($_POST['contact_number'])?$_POST['contact_number']:"";
		$contact_msg = isset($_POST['contact_msg'])?$_POST['contact_msg']:"";

		$to  = 'helpdesk@alphacorp.business'; 
	

		
	    $headers  = 'MIME-Version: 1.0' . "\r\n";
		$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
		$subject = "Contact Page Form";
		$message = "'".$contact_msg."'.
					<table border='2'>
				    	<tr><td>Name:</td><td>".$contact_name."</td></tr>
						<tr><td>Email:</td><td>".$contact_email."</td></tr>
						<tr><td>Phone Number:</td><td>".$contact_number."</td></tr>
						<tr><td>Message:</td><td>".$contact_msg."</td></tr>
					</table>";
//		$message = nl2br($message);
//		if(mail($to, $subject, $message, $headers)){
//		header('location:https://alphacorp.business/thankyou.html');
//		}
	}
		
?>
